diff options
Diffstat (limited to 'src/librustdoc/text_pass.rs')
| -rw-r--r-- | src/librustdoc/text_pass.rs | 42 |
1 files changed, 21 insertions, 21 deletions
diff --git a/src/librustdoc/text_pass.rs b/src/librustdoc/text_pass.rs index 22bdc08a50e..1bd83375607 100644 --- a/src/librustdoc/text_pass.rs +++ b/src/librustdoc/text_pass.rs @@ -140,89 +140,89 @@ fn fold_impl( #[test] fn should_execute_op_on_enum_brief() { let doc = test::mk_doc(~"#[doc = \" a \"] enum a { b }"); - assert doc.cratemod().enums()[0].brief() == Some(~"a"); + fail_unless!(doc.cratemod().enums()[0].brief() == Some(~"a")); } #[test] fn should_execute_op_on_enum_desc() { let doc = test::mk_doc(~"#[doc = \" a \"] enum a { b }"); - assert doc.cratemod().enums()[0].desc() == Some(~"a"); + fail_unless!(doc.cratemod().enums()[0].desc() == Some(~"a")); } #[test] fn should_execute_op_on_variant_desc() { let doc = test::mk_doc(~"enum a { #[doc = \" a \"] b }"); - assert doc.cratemod().enums()[0].variants[0].desc == Some(~"a"); + fail_unless!(doc.cratemod().enums()[0].variants[0].desc == Some(~"a")); } #[test] fn should_execute_op_on_trait_brief() { let doc = test::mk_doc( ~"#[doc = \" a \"] trait i { fn a(); }"); - assert doc.cratemod().traits()[0].brief() == Some(~"a"); + fail_unless!(doc.cratemod().traits()[0].brief() == Some(~"a")); } #[test] fn should_execute_op_on_trait_desc() { let doc = test::mk_doc( ~"#[doc = \" a \"] trait i { fn a(); }"); - assert doc.cratemod().traits()[0].desc() == Some(~"a"); + fail_unless!(doc.cratemod().traits()[0].desc() == Some(~"a")); } #[test] fn should_execute_op_on_trait_method_brief() { let doc = test::mk_doc( ~"trait i { #[doc = \" a \"] fn a(); }"); - assert doc.cratemod().traits()[0].methods[0].brief == Some(~"a"); + fail_unless!(doc.cratemod().traits()[0].methods[0].brief == Some(~"a")); } #[test] fn should_execute_op_on_trait_method_desc() { let doc = test::mk_doc( ~"trait i { #[doc = \" a \"] fn a(); }"); - assert doc.cratemod().traits()[0].methods[0].desc == Some(~"a"); + fail_unless!(doc.cratemod().traits()[0].methods[0].desc == Some(~"a")); } #[test] fn should_execute_op_on_impl_brief() { let doc = test::mk_doc( ~"#[doc = \" a \"] impl int { fn a() { } }"); - assert doc.cratemod().impls()[0].brief() == Some(~"a"); + fail_unless!(doc.cratemod().impls()[0].brief() == Some(~"a")); } #[test] fn should_execute_op_on_impl_desc() { let doc = test::mk_doc( ~"#[doc = \" a \"] impl int { fn a() { } }"); - assert doc.cratemod().impls()[0].desc() == Some(~"a"); + fail_unless!(doc.cratemod().impls()[0].desc() == Some(~"a")); } #[test] fn should_execute_op_on_impl_method_brief() { let doc = test::mk_doc( ~"impl int { #[doc = \" a \"] fn a() { } }"); - assert doc.cratemod().impls()[0].methods[0].brief == Some(~"a"); + fail_unless!(doc.cratemod().impls()[0].methods[0].brief == Some(~"a")); } #[test] fn should_execute_op_on_impl_method_desc() { let doc = test::mk_doc( ~"impl int { #[doc = \" a \"] fn a() { } }"); - assert doc.cratemod().impls()[0].methods[0].desc == Some(~"a"); + fail_unless!(doc.cratemod().impls()[0].methods[0].desc == Some(~"a")); } #[test] fn should_execute_op_on_type_brief() { let doc = test::mk_doc( ~"#[doc = \" a \"] type t = int;"); - assert doc.cratemod().types()[0].brief() == Some(~"a"); + fail_unless!(doc.cratemod().types()[0].brief() == Some(~"a")); } #[test] fn should_execute_op_on_type_desc() { let doc = test::mk_doc( ~"#[doc = \" a \"] type t = int;"); - assert doc.cratemod().types()[0].desc() == Some(~"a"); + fail_unless!(doc.cratemod().types()[0].desc() == Some(~"a")); } #[test] @@ -232,7 +232,7 @@ fn should_execute_on_item_section_headers() { # Header \n\ Body\"]\ fn a() { }"); - assert doc.cratemod().fns()[0].sections()[0].header == ~"Header"; + fail_unless!(doc.cratemod().fns()[0].sections()[0].header == ~"Header"); } #[test] @@ -242,7 +242,7 @@ fn should_execute_on_item_section_bodies() { # Header\n\ Body \"]\ fn a() { }"); - assert doc.cratemod().fns()[0].sections()[0].body == ~"Body"; + fail_unless!(doc.cratemod().fns()[0].sections()[0].body == ~"Body"); } #[test] @@ -253,8 +253,8 @@ fn should_execute_on_trait_method_section_headers() { # Header \n\ Body\"]\ fn a(); }"); - assert doc.cratemod().traits()[0].methods[0].sections[0].header - == ~"Header"; + fail_unless!(doc.cratemod().traits()[0].methods[0].sections[0].header + == ~"Header"); } #[test] @@ -265,7 +265,7 @@ fn should_execute_on_trait_method_section_bodies() { # Header\n\ Body \"]\ fn a(); }"); - assert doc.cratemod().traits()[0].methods[0].sections[0].body == ~"Body"; + fail_unless!(doc.cratemod().traits()[0].methods[0].sections[0].body == ~"Body"); } #[test] @@ -276,8 +276,8 @@ fn should_execute_on_impl_method_section_headers() { # Header \n\ Body\"]\ fn a() { } }"); - assert doc.cratemod().impls()[0].methods[0].sections[0].header - == ~"Header"; + fail_unless!(doc.cratemod().impls()[0].methods[0].sections[0].header + == ~"Header"); } #[test] @@ -288,7 +288,7 @@ fn should_execute_on_impl_method_section_bodies() { # Header\n\ Body \"]\ fn a() { } }"); - assert doc.cratemod().impls()[0].methods[0].sections[0].body == ~"Body"; + fail_unless!(doc.cratemod().impls()[0].methods[0].sections[0].body == ~"Body"); } #[cfg(test)] |
