Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Test a

Source location: tests/basic_tests.rs:356

fn a() -> () { trusted }
}])
p_execute()
);
}

#[test]
_impl_dup() {
alityTest::new(crates![crate core {
trait MyTrait {}
struct MyStruct {}
impl MyTrait for MyStruct {}
impl MyTrait for MyStruct {}
}])
(expect_test::expect![[r#"
the rule "check crate" at (mod.rs) failed because
  `impl MyTrait for MyStruct { }` is defined multiple times"#]]);
}

#[test]
_neg_impl_dup() {
alityTest::new(crates![crate core {
trait MyTrait {}
struct MyStruct {}
impl !MyTrait for MyStruct {}
impl !MyTrait for MyStruct {}
}])
(expect_test::expect![[r#"
the rule "check crate" at (mod.rs) failed because
  `impl ! MyTrait for MyStruct {}` is defined multiple times"#]]);
}

#[test]
items_with_duplicate_fn_names() {
alityTest::new(crates![crate core {
trait Foo {
    fn bar(self_: u32) -> u32;
}

Rules proved (14)

Premises failed (0)

This test records no negative coverage.

Proof trees

Proof tree