mirror of
https://github.com/ziglang/zig.git
synced 2025-12-07 14:53:08 +00:00
Tests with no names are executed when using `zig test` regardless of the `--test-filter` used. Non-named tests should be used when simply importing unit tests from another file. This allows `zig test` to find all the appropriate tests, even when using `--test-filter`.
12 lines
249 B
Zig
12 lines
249 B
Zig
const fixint = @import("fixint.zig").fixint;
|
|
const builtin = @import("builtin");
|
|
|
|
pub fn __fixtfsi(a: f128) callconv(.C) i32 {
|
|
@setRuntimeSafety(builtin.is_test);
|
|
return fixint(f128, i32, a);
|
|
}
|
|
|
|
test {
|
|
_ = @import("fixtfsi_test.zig");
|
|
}
|