1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
// we need to write this statement in integration testing as each file under test directory is
// separate crate
// compiler knows all files under tests folder are integration test files(except under /tests/common/).
/**
* integration test run if all unit tests are passed
*/
use ;
/**
* difference of mod and use is
* mod: is used to add the file to include it to the module tree(main.rs for bin project, lib.rs for unit testing and integration_test.rs
* for integration testing)
* use: is used to access the data from any mod when the module tree file makes other mods public.
*/
// we can only the the integration test using "cargo test --test integration_test " command