From d8cac31decf38fe2f2917062b6e2a349d1f7998b Mon Sep 17 00:00:00 2001 From: Zanie Blue Date: Wed, 20 Dec 2023 21:52:35 -0600 Subject: [PATCH] Update test following pubgrub-rs#163 (#15) * Update test following pubgrub-rs#163 * Fix compiler warning --------- Co-authored-by: konstin --- tests/examples.rs | 6 +++--- tests/proptest.rs | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/examples.rs b/tests/examples.rs index f968bba1..265974b4 100644 --- a/tests/examples.rs +++ b/tests/examples.rs @@ -231,12 +231,12 @@ fn confusing_with_lots_of_holes() { }; assert_eq!( &DefaultStringReporter::report(&derivation_tree), - r#"Because there is no available version for bar and foo 1 | 2 | 3 | 4 | 5 depends on bar, foo 1 | 2 | 3 | 4 | 5 is forbidden. -And because there is no version of foo in <1 | >1, <2 | >2, <3 | >3, <4 | >4, <5 | >5 and root 1 depends on foo, root 1 is forbidden."# + r#"Because there is no available version for bar and foo ==1 | ==2 | ==3 | ==4 | ==5 depends on bar, foo ==1 | ==2 | ==3 | ==4 | ==5 is forbidden. +And because there is no version of foo in <1 | >1, <2 | >2, <3 | >3, <4 | >4, <5 | >5 and root ==1 depends on foo, root ==1 is forbidden."# ); derivation_tree.collapse_no_versions(); assert_eq!( &DefaultStringReporter::report(&derivation_tree), - "Because foo depends on bar and root 1 depends on foo, root 1 is forbidden." + "Because foo depends on bar and root ==1 depends on foo, root ==1 is forbidden." ); } diff --git a/tests/proptest.rs b/tests/proptest.rs index d73567a7..0d563d39 100644 --- a/tests/proptest.rs +++ b/tests/proptest.rs @@ -598,7 +598,7 @@ fn large_case() { let mut sat = SatResolve::new(&dependency_provider); for p in dependency_provider.packages() { for v in dependency_provider.versions(p).unwrap() { - let res = resolve(&dependency_provider, p.clone(), v); + let res = resolve(&dependency_provider, *p, v); sat.check_resolve(&res, p, v); } }