Skip to content

Commit

Permalink
Implement assert_non_crate_hash_different for tests
Browse files Browse the repository at this point in the history
  • Loading branch information
jsgf committed Jun 22, 2021
1 parent a26d99f commit 48921ce
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions compiler/rustc_interface/src/tests.rs
Expand Up @@ -96,6 +96,14 @@ fn assert_different_hash(x: &Options, y: &Options) {
assert_same_clone(y);
}

fn assert_non_crate_hash_different(x: &Options, y: &Options) {
assert_eq!(x.dep_tracking_hash(true), y.dep_tracking_hash(true));
assert_ne!(x.dep_tracking_hash(false), y.dep_tracking_hash(false));
// Check clone
assert_same_clone(x);
assert_same_clone(y);
}

// When the user supplies --test we should implicitly supply --cfg test
#[test]
fn test_switch_implies_cfg_test() {
Expand Down

0 comments on commit 48921ce

Please sign in to comment.