@@ -926,6 +926,7 @@ fn dry_run_update() {
926
926
[UPDATING] serde v0.1.0 -> v0.1.1
927
927
[NOTE] pass `--verbose` to see 1 unchanged dependencies behind latest
928
928
[WARNING] not updating lockfile due to dry run
929
+ [WARNING] aborting update due to dry run
929
930
930
931
"# ] ] )
931
932
. run ( ) ;
@@ -1525,6 +1526,7 @@ fn report_behind() {
1525
1526
[UPDATING] breaking v0.1.0 -> v0.1.1 (latest: v0.2.0)
1526
1527
[NOTE] pass `--verbose` to see 2 unchanged dependencies behind latest
1527
1528
[WARNING] not updating lockfile due to dry run
1529
+ [WARNING] aborting update due to dry run
1528
1530
1529
1531
"# ] ] )
1530
1532
. run ( ) ;
@@ -1538,6 +1540,7 @@ fn report_behind() {
1538
1540
[UNCHANGED] two-ver v0.1.0 (latest: v0.2.0)
1539
1541
[NOTE] to see how you depend on a package, run `cargo tree --invert --package <dep>@<ver>`
1540
1542
[WARNING] not updating lockfile due to dry run
1543
+ [WARNING] aborting update due to dry run
1541
1544
1542
1545
"# ] ] )
1543
1546
. run ( ) ;
@@ -1550,6 +1553,7 @@ fn report_behind() {
1550
1553
[LOCKING] 0 packages to latest compatible versions
1551
1554
[NOTE] pass `--verbose` to see 3 unchanged dependencies behind latest
1552
1555
[WARNING] not updating lockfile due to dry run
1556
+ [WARNING] aborting update due to dry run
1553
1557
1554
1558
"# ] ] )
1555
1559
. run ( ) ;
@@ -1563,6 +1567,7 @@ fn report_behind() {
1563
1567
[UNCHANGED] two-ver v0.1.0 (latest: v0.2.0)
1564
1568
[NOTE] to see how you depend on a package, run `cargo tree --invert --package <dep>@<ver>`
1565
1569
[WARNING] not updating lockfile due to dry run
1570
+ [WARNING] aborting update due to dry run
1566
1571
1567
1572
"# ] ] )
1568
1573
. run ( ) ;
@@ -1695,6 +1700,7 @@ fn update_breaking_dry_run() {
1695
1700
[LOCKING] 2 packages to latest compatible versions
1696
1701
[UPDATING] incompatible v1.0.0 -> v2.0.0
1697
1702
[UPDATING] ws v1.0.0 -> v2.0.0
1703
+ [WARNING] not updating lockfile due to dry run
1698
1704
[WARNING] aborting update due to dry run
1699
1705
1700
1706
"# ] ] )
@@ -1912,10 +1918,13 @@ fn update_breaking() {
1912
1918
[UPDATING] multiple-registries v2.0.0 (registry `alternative`) -> v3.0.0
1913
1919
[UPDATING] multiple-registries v1.0.0 -> v2.0.0
1914
1920
[UPDATING] multiple-source-types v1.0.0 -> v2.0.0
1921
+ [REMOVING] multiple-versions v1.0.0
1922
+ [REMOVING] multiple-versions v2.0.0
1915
1923
[ADDING] multiple-versions v3.0.0
1916
1924
[UPDATING] platform-specific v1.0.0 -> v2.0.0
1917
1925
[UPDATING] shared v1.0.0 -> v2.0.0
1918
1926
[UPDATING] ws v1.0.0 -> v2.0.0
1927
+ [NOTE] pass `--verbose` to see 4 unchanged dependencies behind latest
1919
1928
1920
1929
"# ] ] )
1921
1930
. run ( ) ;
@@ -2108,6 +2117,7 @@ fn update_breaking_specific_packages() {
2108
2117
[UPDATING] transitive-compatible v1.0.0 -> v1.0.1
2109
2118
[UPDATING] transitive-incompatible v1.0.0 -> v2.0.0
2110
2119
[UPDATING] ws v1.0.0 -> v2.0.0
2120
+ [NOTE] pass `--verbose` to see 1 unchanged dependencies behind latest
2111
2121
2112
2122
"# ] ] )
2113
2123
. run ( ) ;
@@ -2163,6 +2173,8 @@ fn update_breaking_specific_packages_that_wont_update() {
2163
2173
. masquerade_as_nightly_cargo ( & [ "update-breaking" ] )
2164
2174
. with_stderr_data ( str![ [ r#"
2165
2175
[UPDATING] `dummy-registry` index
2176
+ [LOCKING] 0 packages to latest compatible versions
2177
+ [NOTE] pass `--verbose` to see 5 unchanged dependencies behind latest
2166
2178
2167
2179
"# ] ] )
2168
2180
. run ( ) ;
@@ -2271,14 +2283,27 @@ fn update_breaking_spec_version() {
2271
2283
// Spec version not matching our current dependencies
2272
2284
p
. cargo ( "update -Zunstable-options --breaking [email protected] " )
2273
2285
. masquerade_as_nightly_cargo ( & [ "update-breaking" ] )
2274
- . with_stderr_data ( str![ [ r#""# ] ] )
2286
+ . with_status ( 101 )
2287
+ . with_stderr_data ( str![ [ r#"
2288
+ [ERROR] package ID specification `[email protected] ` did not match any packages
2289
+ Did you mean one of these?
2290
+
2291
+
2292
+
2293
+ "# ] ] )
2275
2294
. run ( ) ;
2276
2295
2277
2296
// Spec source not matching our current dependencies
2278
2297
p
. cargo ( "update -Zunstable-options --breaking https://alternative.com#[email protected] " )
2279
2298
. masquerade_as_nightly_cargo ( & [ "update-breaking" ] )
2280
- . with_stderr_data ( str![ [ r#""# ] ] )
2281
- . run ( ) ;
2299
+ . with_status ( 101 )
2300
+ . with_stderr_data ( str![ [ r#"
2301
+ [ERROR] package ID specification `https://alternative.com/#[email protected] ` did not match any packages
2302
+ Did you mean one of these?
2303
+
2304
+
2305
+
2306
+ "# ] ] ) . run ( ) ;
2282
2307
2283
2308
// Accepted spec
2284
2309
p
. cargo ( "update -Zunstable-options --breaking [email protected] " )
@@ -2288,6 +2313,7 @@ fn update_breaking_spec_version() {
2288
2313
[UPGRADING] incompatible ^1.0 -> ^2.0
2289
2314
[LOCKING] 1 package to latest compatible version
2290
2315
[UPDATING] incompatible v1.0.0 -> v2.0.0
2316
+ [NOTE] pass `--verbose` to see 1 unchanged dependencies behind latest
2291
2317
2292
2318
"# ] ] )
2293
2319
. run ( ) ;
@@ -2301,6 +2327,7 @@ fn update_breaking_spec_version() {
2301
2327
[UPGRADING] incompatible ^2.0 -> ^3.0
2302
2328
[LOCKING] 1 package to latest compatible version
2303
2329
[UPDATING] incompatible v2.0.0 -> v3.0.0
2330
+ [NOTE] pass `--verbose` to see 1 unchanged dependencies behind latest
2304
2331
2305
2332
"# ] ] )
2306
2333
. run ( ) ;
@@ -2310,19 +2337,35 @@ fn update_breaking_spec_version() {
2310
2337
. masquerade_as_nightly_cargo ( & [ "update-breaking" ] )
2311
2338
. with_stderr_data ( str![ [ r#"
2312
2339
[UPDATING] `dummy-registry` index
2340
+ [LOCKING] 0 packages to latest compatible versions
2341
+ [NOTE] pass `--verbose` to see 1 unchanged dependencies behind latest
2313
2342
2314
2343
"# ] ] )
2315
2344
. run ( ) ;
2316
2345
2317
2346
// Non-existing versions
2318
2347
p
. cargo ( "update -Zunstable-options --breaking [email protected] " )
2319
2348
. masquerade_as_nightly_cargo ( & [ "update-breaking" ] )
2320
- . with_stderr_data ( str![ [ r#""# ] ] )
2349
+ . with_status ( 101 )
2350
+ . with_stderr_data ( str![ [ r#"
2351
+ [ERROR] package ID specification `[email protected] ` did not match any packages
2352
+ Did you mean one of these?
2353
+
2354
+
2355
+
2356
+ "# ] ] )
2321
2357
. run ( ) ;
2322
2358
2323
2359
p
. cargo ( "update -Zunstable-options --breaking [email protected] " )
2324
2360
. masquerade_as_nightly_cargo ( & [ "update-breaking" ] )
2325
- . with_stderr_data ( str![ [ r#""# ] ] )
2361
+ . with_status ( 101 )
2362
+ . with_stderr_data ( str![ [ r#"
2363
+ [ERROR] package ID specification `[email protected] ` did not match any packages
2364
+ Did you mean one of these?
2365
+
2366
+
2367
+
2368
+ "# ] ] )
2326
2369
. run ( ) ;
2327
2370
}
2328
2371
@@ -2376,6 +2419,7 @@ fn update_breaking_spec_version_transitive() {
2376
2419
[UPGRADING] dep ^1.0 -> ^3.0
2377
2420
[LOCKING] 1 package to latest compatible version
2378
2421
[UPDATING] dep v1.0.0 -> v3.0.0
2422
+ [NOTE] pass `--verbose` to see 1 unchanged dependencies behind latest
2379
2423
2380
2424
"# ] ] )
2381
2425
. run ( ) ;
@@ -2385,6 +2429,8 @@ fn update_breaking_spec_version_transitive() {
2385
2429
. masquerade_as_nightly_cargo ( & [ "update-breaking" ] )
2386
2430
. with_stderr_data ( str![ [ r#"
2387
2431
[UPDATING] `dummy-registry` index
2432
+ [LOCKING] 0 packages to latest compatible versions
2433
+ [NOTE] pass `--verbose` to see 1 unchanged dependencies behind latest
2388
2434
2389
2435
"# ] ] )
2390
2436
. run ( ) ;
@@ -2453,6 +2499,8 @@ fn update_breaking_mixed_compatibility() {
2453
2499
[UPDATING] `dummy-registry` index
2454
2500
[UPGRADING] mixed-compatibility ^1.0 -> ^2.0
2455
2501
[LOCKING] 1 package to latest compatible version
2502
+ [REMOVING] mixed-compatibility v1.0.0
2503
+ [REMOVING] mixed-compatibility v2.0.0
2456
2504
[ADDING] mixed-compatibility v2.0.1
2457
2505
2458
2506
"# ] ] )
@@ -2544,6 +2592,7 @@ fn update_breaking_mixed_pinning_renaming() {
2544
2592
[ADDING] mixed-pinned v2.0.0
2545
2593
[ADDING] mixed-ws-pinned v2.0.0
2546
2594
[ADDING] renamed-from v2.0.0
2595
+ [NOTE] pass `--verbose` to see 3 unchanged dependencies behind latest
2547
2596
2548
2597
"# ] ] )
2549
2598
. run ( ) ;
0 commit comments