@@ -12,10 +12,16 @@ setup()
12
12
name = "$PROJECT "
13
13
version = "0.1.0"
14
14
authors = ["Andrew Hobden <[email protected] >"]
15
+
16
+ [dependencies]
17
+ rand = "*"
15
18
EOF
16
19
cat > $BUILD_DIR /src/main.rs << EOF
20
+ extern crate rand;
21
+
17
22
fn main() {
18
- println!("Hello world!");
23
+ let number = rand::random::<u64>();
24
+ println!("Hello world! Some random number is {}", number);
19
25
}
20
26
21
27
#[test]
@@ -38,13 +44,17 @@ testDefault()
38
44
39
45
compile
40
46
41
- assertCaptured " -----> Fetching multirust."
42
- assertCaptured " -----> Setting version to \" nightly\" (default)."
43
- assertCaptured " -----> Compiling Application."
47
+ assertCaptured " -----> Fetching multirust"
48
+ assertCaptured " -----> Setting version to \" nightly\" (default)"
49
+ assertCaptured " -----> No cached crates detected"
50
+ assertCaptured " -----> Compiling application"
51
+ assertCaptured " -----> Caching build artifacts"
44
52
45
53
compile
46
54
47
- assertCaptured " -----> Pre-existing multirust."
55
+ assertCaptured " -----> Pre-existing multirust"
56
+ assertCaptured " multirust: using existing install for"
57
+ assertCaptured " -----> Detected cached crates... Restoring..."
48
58
49
59
cleanup
50
60
}
59
69
60
70
compile
61
71
62
- assertCaptured " -----> Fetching multirust."
63
- assertCaptured " -----> Setting version to \" nightly\" ."
64
- assertCaptured " -----> Compiling Application."
72
+ assertCaptured " -----> Fetching multirust"
73
+ assertCaptured " -----> Setting version to \" nightly\" "
74
+ assertCaptured " -----> No cached crates detected"
75
+ assertCaptured " -----> Compiling application"
76
+ assertCaptured " -----> Caching build artifacts"
65
77
66
78
cleanup
67
79
}
76
88
77
89
compile
78
90
79
- assertCaptured " -----> Fetching multirust."
80
- assertCaptured " -----> Setting version to \" beta\" ."
81
- assertCaptured " -----> Compiling Application."
91
+ assertCaptured " -----> Fetching multirust"
92
+ assertCaptured " -----> Setting version to \" beta\" "
93
+ assertCaptured " -----> No cached crates detected"
94
+ assertCaptured " -----> Compiling application"
95
+ assertCaptured " -----> Caching build artifacts"
82
96
83
97
cleanup
84
98
}
93
107
94
108
compile
95
109
96
- assertCaptured " -----> Fetching multirust."
97
- assertCaptured " -----> Setting version to \" stable\" ."
98
- assertCaptured " -----> Compiling Application."
110
+ assertCaptured " -----> Fetching multirust"
111
+ assertCaptured " -----> Setting version to \" stable\" "
112
+ assertCaptured " -----> No cached crates detected"
113
+ assertCaptured " -----> Compiling application"
114
+ assertCaptured " -----> Caching build artifacts"
99
115
100
116
cleanup
101
117
}
0 commit comments