Test(lib/win/net): Skip UDS tests when under Win7#152534
Test(lib/win/net): Skip UDS tests when under Win7#152534rust-bors[bot] merged 1 commit intorust-lang:mainfrom
Conversation
|
rustbot has assigned @Mark-Simulacrum. Use Why was this reviewer chosen?The reviewer was selected based on:
|
|
Does this just disable the whole module? If so, I don't think that's the right way to go - The win7 target lowers the minimum supported windows version, but it shouldn't cfg out entire standard APIs, especially since some people might still want to use those APIs when running on a newer version of windows. As far as I can tell, the UDS feature doesn't even cause any link-time error (since it uses existing functions with new parameters), so the only thing we really need to do is add some version checking in the test code to ignore the test when running on a win7 machine. |
|
Ah, you're right, I went a bit too quick there. Will do, then. |
Unix Domain Socket support has only been added to Windows since Windows 10 Insider Preview Build 17063. Thus, it has no chance of ever being supported under Windows 7, making current tests fail. This therefore adds the necessary in order to make the tests dynamically skip when run under Windows 7, 8, and early 10, as it does not trigger linker errors. Signed-off-by: Paul Mabileau <paul.mabileau@harfanglab.fr>
bc65b8e to
c22301b
Compare
| } | ||
|
|
||
| /// Returns true if we are currently running on Windows 10 v1803 (RS4) or greater. | ||
| fn is_windows_10_v1803_or_greater() -> bool { |
There was a problem hiding this comment.
Hm, it seems a bit surprising to me that this is the first time we have code of this shape. I guess it seems fine to add it here for now (vs., e.g., in std::os::windows or something like that).
There was a problem hiding this comment.
Yeah, I had searched for instances of RtlVerifyVersionInfo or RtlGetVersion, but couldn't find any yet. The platform version API did not seem to go beyond macOS for now from what I had seen, so adding its Windows variant seemed like a bit much for the intended fix.
|
@bors r+ |
Rollup of 9 pull requests Successful merges: - #150424 (diagnostics: add note when param-env shadows global impl) - #152132 (implement `carryless_mul`) - #152508 (Improve write! and writeln! error when called without destination) - #152534 (Test(lib/win/net): Skip UDS tests when under Win7) - #152578 (ci: Lock cross toolchain version and update docs) - #152188 (Include `library/stdarch` for `CURRENT_RUSTC_VERSION` updates) - #152402 (Add regression test for #141738) - #152472 (unwind/wasm: fix compile error by wrapping wasm_throw in unsafe block) - #152610 (Exchange js_lint message between bless and non-bless)
Rollup merge of #152534 - PaulDance:patches/remove-win7-uds, r=Mark-Simulacrum Test(lib/win/net): Skip UDS tests when under Win7 Unix Domain Socket support has only been added to Windows since Windows 10 Insider Preview Build 17063. Thus, it has no chance of ever being supported under Windows 7, making current tests fail. This therefore adds the necessary in order to make the tests dynamically skip when run under Windows 7, 8, and early 10, as it does not trigger linker errors. cc #150487 @roblabla @rustbot label T-libs A-io O-windows-7
|
👍 |
Rollup of 9 pull requests Successful merges: - rust-lang/rust#150424 (diagnostics: add note when param-env shadows global impl) - rust-lang/rust#152132 (implement `carryless_mul`) - rust-lang/rust#152508 (Improve write! and writeln! error when called without destination) - rust-lang/rust#152534 (Test(lib/win/net): Skip UDS tests when under Win7) - rust-lang/rust#152578 (ci: Lock cross toolchain version and update docs) - rust-lang/rust#152188 (Include `library/stdarch` for `CURRENT_RUSTC_VERSION` updates) - rust-lang/rust#152402 (Add regression test for rust-lang/rust#141738) - rust-lang/rust#152472 (unwind/wasm: fix compile error by wrapping wasm_throw in unsafe block) - rust-lang/rust#152610 (Exchange js_lint message between bless and non-bless)
Unix Domain Socket support has only been added to Windows since Windows 10 Insider Preview Build 17063. Thus, it has no chance of ever being supported under Windows 7, making current tests fail. This therefore adds the necessary in order to make the tests dynamically skip when run under Windows 7, 8, and early 10, as it does not trigger linker errors.
cc #150487 @roblabla
@rustbot label T-libs A-io O-windows-7