@@ -14,28 +14,28 @@ fn cargo_build_plan_simple() {
14
14
. masquerade_as_nightly_cargo ( )
15
15
. with_json (
16
16
r#"
17
- {
18
- "inputs": [
19
- "[..]/foo/Cargo.toml"
20
- ],
21
- "invocations": [
22
17
{
23
- "args": "{...}",
24
- "cwd": "[..]/cit/[..]/foo",
25
- "deps": [],
26
- "env": "{...}",
27
- "kind": null,
28
- "links": "{...}",
29
- "outputs": "{...}",
30
- "package_name": "foo",
31
- "package_version": "0.5.0",
32
- "program": "rustc",
33
- "target_kind": ["bin"],
34
- "compile_mode": "build"
18
+ "inputs": [
19
+ "[..]/foo/Cargo.toml"
20
+ ],
21
+ "invocations": [
22
+ {
23
+ "args": "{...}",
24
+ "cwd": "[..]/cit/[..]/foo",
25
+ "deps": [],
26
+ "env": "{...}",
27
+ "kind": null,
28
+ "links": "{...}",
29
+ "outputs": "{...}",
30
+ "package_name": "foo",
31
+ "package_version": "0.5.0",
32
+ "program": "rustc",
33
+ "target_kind": ["bin"],
34
+ "compile_mode": "build"
35
+ }
36
+ ]
35
37
}
36
- ]
37
- }
38
- "# ,
38
+ "# ,
39
39
)
40
40
. run ( ) ;
41
41
assert ! ( !p. bin( "foo" ) . is_file( ) ) ;
@@ -47,24 +47,24 @@ fn cargo_build_plan_single_dep() {
47
47
. file (
48
48
"Cargo.toml" ,
49
49
r#"
50
- [package]
51
- name = "foo"
52
- authors = []
53
- version = "0.5.0"
50
+ [package]
51
+ name = "foo"
52
+ authors = []
53
+ version = "0.5.0"
54
54
55
- [dependencies]
56
- bar = { path = "bar" }
57
- "# ,
55
+ [dependencies]
56
+ bar = { path = "bar" }
57
+ "# ,
58
58
)
59
59
. file (
60
60
"src/lib.rs" ,
61
61
r#"
62
- extern crate bar;
63
- pub fn foo() { bar::bar(); }
62
+ extern crate bar;
63
+ pub fn foo() { bar::bar(); }
64
64
65
- #[test]
66
- fn test() { foo(); }
67
- "# ,
65
+ #[test]
66
+ fn test() { foo(); }
67
+ "# ,
68
68
)
69
69
. file ( "bar/Cargo.toml" , & basic_manifest ( "bar" , "0.0.1" ) )
70
70
. file ( "bar/src/lib.rs" , "pub fn bar() {}" )
@@ -73,49 +73,49 @@ fn cargo_build_plan_single_dep() {
73
73
. masquerade_as_nightly_cargo ( )
74
74
. with_json (
75
75
r#"
76
- {
77
- "inputs": [
78
- "[..]/foo/Cargo.toml",
79
- "[..]/foo/bar/Cargo.toml"
80
- ],
81
- "invocations": [
82
- {
83
- "args": "{...}",
84
- "cwd": "[..]/cit/[..]/foo",
85
- "deps": [],
86
- "env": "{...}",
87
- "kind": null,
88
- "links": "{...}",
89
- "outputs": [
90
- "[..]/foo/target/debug/deps/libbar-[..].rlib",
91
- "[..]/foo/target/debug/deps/libbar-[..].rmeta"
92
- ],
93
- "package_name": "bar",
94
- "package_version": "0.0.1",
95
- "program": "rustc",
96
- "target_kind": ["lib"],
97
- "compile_mode": "build"
98
- },
99
76
{
100
- "args": "{...}",
101
- "cwd": "[..]/cit/[..]/foo",
102
- "deps": [0],
103
- "env": "{...}",
104
- "kind": null,
105
- "links": "{...}",
106
- "outputs": [
107
- "[..]/foo/target/debug/deps/libfoo-[..].rlib",
108
- "[..]/foo/target/debug/deps/libfoo-[..].rmeta"
77
+ "inputs": [
78
+ "[..]/foo/Cargo.toml",
79
+ "[..]/foo/bar/Cargo.toml"
109
80
],
110
- "package_name": "foo",
111
- "package_version": "0.5.0",
112
- "program": "rustc",
113
- "target_kind": ["lib"],
114
- "compile_mode": "build"
81
+ "invocations": [
82
+ {
83
+ "args": "{...}",
84
+ "cwd": "[..]/cit/[..]/foo",
85
+ "deps": [],
86
+ "env": "{...}",
87
+ "kind": null,
88
+ "links": "{...}",
89
+ "outputs": [
90
+ "[..]/foo/target/debug/deps/libbar-[..].rlib",
91
+ "[..]/foo/target/debug/deps/libbar-[..].rmeta"
92
+ ],
93
+ "package_name": "bar",
94
+ "package_version": "0.0.1",
95
+ "program": "rustc",
96
+ "target_kind": ["lib"],
97
+ "compile_mode": "build"
98
+ },
99
+ {
100
+ "args": "{...}",
101
+ "cwd": "[..]/cit/[..]/foo",
102
+ "deps": [0],
103
+ "env": "{...}",
104
+ "kind": null,
105
+ "links": "{...}",
106
+ "outputs": [
107
+ "[..]/foo/target/debug/deps/libfoo-[..].rlib",
108
+ "[..]/foo/target/debug/deps/libfoo-[..].rmeta"
109
+ ],
110
+ "package_name": "foo",
111
+ "package_version": "0.5.0",
112
+ "program": "rustc",
113
+ "target_kind": ["lib"],
114
+ "compile_mode": "build"
115
+ }
116
+ ]
115
117
}
116
- ]
117
- }
118
- "# ,
118
+ "# ,
119
119
)
120
120
. run ( ) ;
121
121
}
@@ -126,13 +126,13 @@ fn cargo_build_plan_build_script() {
126
126
. file (
127
127
"Cargo.toml" ,
128
128
r#"
129
- [project]
129
+ [project]
130
130
131
- name = "foo"
132
- version = "0.5.0"
133
-
134
- build = "build.rs"
135
- "# ,
131
+ name = "foo"
132
+ version = "0.5.0"
133
+
134
+ build = "build.rs"
135
+ "# ,
136
136
)
137
137
. file ( "src/main.rs" , r#"fn main() {}"# )
138
138
. file ( "build.rs" , r#"fn main() {}"# )
@@ -142,56 +142,56 @@ fn cargo_build_plan_build_script() {
142
142
. masquerade_as_nightly_cargo ( )
143
143
. with_json (
144
144
r#"
145
- {
146
- "inputs": [
147
- "[..]/foo/Cargo.toml"
148
- ],
149
- "invocations": [
150
145
{
151
- "args": "{...}",
152
- "cwd": "[..]/cit/[..]/foo",
153
- "deps": [],
154
- "env": "{...}",
155
- "kind": null,
156
- "links": "{...}",
157
- "outputs": "{...}",
158
- "package_name": "foo",
159
- "package_version": "0.5.0",
160
- "program": "rustc",
161
- "target_kind": ["custom-build"],
162
- "compile_mode": "build"
163
- },
164
- {
165
- "args": "{...}",
166
- "cwd": "[..]/cit/[..]/foo",
167
- "deps": [0],
168
- "env": "{...}",
169
- "kind": null,
170
- "links": "{...}",
171
- "outputs": [],
172
- "package_name": "foo",
173
- "package_version": "0.5.0",
174
- "program": "[..]/build-script-build",
175
- "target_kind": ["custom-build"],
176
- "compile_mode": "run-custom-build"
177
- },
178
- {
179
- "args": "{...}",
180
- "cwd": "[..]/cit/[..]/foo",
181
- "deps": [1],
182
- "env": "{...}",
183
- "kind": null,
184
- "links": "{...}",
185
- "outputs": "{...}",
186
- "package_name": "foo",
187
- "package_version": "0.5.0",
188
- "program": "rustc",
189
- "target_kind": ["bin"],
190
- "compile_mode": "build"
146
+ "inputs": [
147
+ "[..]/foo/Cargo.toml"
148
+ ],
149
+ "invocations": [
150
+ {
151
+ "args": "{...}",
152
+ "cwd": "[..]/cit/[..]/foo",
153
+ "deps": [],
154
+ "env": "{...}",
155
+ "kind": null,
156
+ "links": "{...}",
157
+ "outputs": "{...}",
158
+ "package_name": "foo",
159
+ "package_version": "0.5.0",
160
+ "program": "rustc",
161
+ "target_kind": ["custom-build"],
162
+ "compile_mode": "build"
163
+ },
164
+ {
165
+ "args": "{...}",
166
+ "cwd": "[..]/cit/[..]/foo",
167
+ "deps": [0],
168
+ "env": "{...}",
169
+ "kind": null,
170
+ "links": "{...}",
171
+ "outputs": [],
172
+ "package_name": "foo",
173
+ "package_version": "0.5.0",
174
+ "program": "[..]/build-script-build",
175
+ "target_kind": ["custom-build"],
176
+ "compile_mode": "run-custom-build"
177
+ },
178
+ {
179
+ "args": "{...}",
180
+ "cwd": "[..]/cit/[..]/foo",
181
+ "deps": [1],
182
+ "env": "{...}",
183
+ "kind": null,
184
+ "links": "{...}",
185
+ "outputs": "{...}",
186
+ "package_name": "foo",
187
+ "package_version": "0.5.0",
188
+ "program": "rustc",
189
+ "target_kind": ["bin"],
190
+ "compile_mode": "build"
191
+ }
192
+ ]
191
193
}
192
- ]
193
- }
194
- "# ,
194
+ "# ,
195
195
)
196
196
. run ( ) ;
197
197
}
0 commit comments