zng/tests
Samuel Guerra 49bd2c5c5d More var and config sync work. 2023-06-20 23:57:40 -03:00
..
build Fixed test. 2023-06-19 19:43:22 -03:00
detached_crates Tested and fixed some widget macro import issues. 2023-04-15 16:01:20 -03:00
Cargo.toml Text API work, emoji segmentation. 2023-06-17 23:27:34 -03:00
README.md Reorganized project folders. 2021-12-15 20:43:05 -03:00
command.rs More refactor. 2023-04-22 12:04:32 -03:00
config.rs More var and config sync work. 2023-06-20 23:57:40 -03:00
focus.rs Fixed layer example. 2023-06-18 20:00:16 -03:00
image.rs Fixed bug discovered in image integration test. 2023-06-18 16:23:39 -03:00
text.rs Text API work, emoji segmentation. 2023-06-17 23:27:34 -03:00

README.md

Tests

Use this directory for integration, build tests or any test that is not a unit test.

Running

Use cargo do test -t command to run tests in the ./command.rs file.

Use cargo do test -b * to run all build tests.

Use cargo do test -b property/* to run build test cases that match the path relative to ./build/cases.

Adding an Integration Test

To add an integration test, create a file then add it in ./Cargo.toml as a [[bin]].

In ./foo.rs:

use zero_ui::prelude::*;

#[test]
fn foo() {
    assert!(true);
}

Then add in ./Cargo.toml:

[[test]]
name = "foo"
path = "foo.rs"

Then run from the project root using cargo do test -t foo.