about summary refs log tree commit diff
path: root/tests/ui/std
AgeCommit message (Collapse)AuthorLines
2025-09-12Add test batch 3Oneirical-0/+28
2025-08-19bless tests with new lint messagesKarol Zwolak-1/+1
2025-07-19tests: Require `run-fail` ui tests to have an exit code (`SIGABRT` not ok)Martin Nordholts-1/+1
And introduce two new directives for ui tests: * `run-crash` * `run-fail-or-crash` Normally a `run-fail` ui test like tests that panic shall not be terminated by a signal like `SIGABRT`. So begin having that as a hard requirement. Some of our current tests do terminate by a signal/crash however. Introduce and use `run-crash` for those tests. Note that Windows crashes are not handled by signals but by certain high bits set on the process exit code. Example exit code for crash on Windows: `0xc000001d`. Because of this, we define "crash" on all platforms as "not exit with success and not exit with a regular failure code in the range 1..=127". Some tests behave differently on different targets: * Targets without unwind support will abort (crash) instead of exit with failure code 101 after panicking. As a special case, allow crashes for `run-fail` tests for such targets. * Different sanitizer implementations handle detected memory problems differently. Some abort (crash) the process while others exit with failure code 1. Introduce and use `run-fail-or-crash` for such tests.
2025-07-05cleaned up some testsKivooeo-7/+13
2025-07-01moved testsKivooeo-0/+48
2025-03-19Specify a concrete stack size in channel testsJeff Martin-5/+15
The channel-stack-overflow-issue-102246 regression test fails on platforms with a small default stack size (e.g. Fuchsia, with a default of 256KiB). Update the test to specify an exact stack size for both the sender and receiver operations, to ensure it is platform agnostic. Set the stack size to less than the total allocation size of the mpsc channel, to continue to prove that the allocation is on the heap.
2025-01-23tests: cleanup `tests/ui/std/thread-sleep-ms.rs`许杰友 Jieyou Xu (Joe)-7/+4
- Use `needs-threads` instead of `ignore-sgx`. - Remove unnecessary import and `#![allow(unused_import)]`.
2024-11-07This test needs threadsJosh Stone-0/+1
2024-11-07Initialize channel `Block`s directly on the heapJosh Stone-0/+28
The channel's `Block::new` was causing a stack overflow because it held 32 item slots, instantiated on the stack before moving to `Box::new`. The 32x multiplier made modestly-large item sizes untenable. That block is now initialized directly on the heap. Fixes #102246
2024-10-15Fix most ui tests on emscripten targetHood Chatham-0/+12
To fix the linker errors, we need to set the output extension to `.js` instead of `.wasm`. Setting the output to a `.wasm` file puts Emscripten into standalone mode which is effectively a distinct target. We need to set the runner to be `node` as well. This fixes most of the ui tests. I fixed a few more tests with simple problems: - `intrinsics/intrinsic-alignment.rs` and `structs-enums/rec-align-u64.rs` -- Two `#[cfg]` macros match for Emscripten so we got a duplicate definition of `mod m`. - `issues/issue-12699.rs` -- Seems to hang so I disabled it - `process/process-sigpipe.rs` -- Not expected to work on Emscripten so I disabled it
2024-09-03More robust extension checkingChris Denton-1/+3
2024-04-28Move various stdlib tests to library/std/testsRyan Lowe-9/+0
2024-04-09Use new-style directives in ui testChris Denton-3/+3
2024-04-09Disallow or quote all specials in bat argsChris Denton-0/+93
2024-03-03Move testsCaio-0/+193
2024-02-16[AUTO-GENERATED] Migrate ui tests from `//` to `//@` directives许杰友 Jieyou Xu (Joe)-5/+5
2023-08-14Add a regression test for #113238Josh Stone-0/+9
2023-06-07Move two tests from `tests/ui/std` to `library/std/tests`MoskalykA-109/+0
2023-04-13Fix tests on wasmJoshua Nelson-0/+1
The `std` test straightforwardly can't work without file descriptors; #99417 tracks moving it out of tests/ui. `issue-13560.rs` requires the target to support dynamic linking. `extern-mod-syntax` is interesting. The original test was added to check if `extern mod` could be parsed correctly and used `extern mod std` and an import: https://github.com/rust-lang/rust/commit/138dc3048af36f0a20f857542c357fe8df563013#diff-73700e1e851b7a37bc92174635dab726124c82e5bfabbbc45b4a3c2e8e14fadd At some point `std::json::Object` was moved out of std to an unstable rustc-only `extras` crate, and rather than just changing the import it got changed to use the unstable crate. When `extras` was removed, people assumed the test was meant to also test rustc_private and changed it to another unstable crate rather than using something in std. This changes the test to remove the `rustc_private` import, to allow it to work properly when cross-compiling.
2023-04-13Move most ui-fulldeps tests to uijyn-0/+258
They pass fine. Only tests that required `extern crate rustc_*` or were marked `ignore-stage1` have been keep in fulldeps.