diff --git a/exercises/practice/allergies/.meta/test_template.tera b/exercises/practice/allergies/.meta/test_template.tera index 3f222d638..05e5615cd 100644 --- a/exercises/practice/allergies/.meta/test_template.tera +++ b/exercises/practice/allergies/.meta/test_template.tera @@ -5,7 +5,7 @@ use allergies::*; #[test] #[ignore] {%- if test.property == "allergicTo" %} -{# canonical data contains multiple cases named "allergic to everything" for different items #} +{#- canonical data contains multiple cases named "allergic to everything" for different items #} fn {{ test.description | make_ident }}_{{ test.input.item }}() { let allergies = Allergies::new({{ test.input.score }}); {%- if test.expected %} diff --git a/exercises/practice/allergies/tests/allergies.rs b/exercises/practice/allergies/tests/allergies.rs index 62795f5ed..35e31bba4 100644 --- a/exercises/practice/allergies/tests/allergies.rs +++ b/exercises/practice/allergies/tests/allergies.rs @@ -1,7 +1,6 @@ use allergies::*; #[test] - fn not_allergic_to_anything_eggs() { let allergies = Allergies::new(0); assert!(!allergies.is_allergic_to(&Allergen::Eggs)) @@ -9,7 +8,6 @@ fn not_allergic_to_anything_eggs() { #[test] #[ignore] - fn allergic_only_to_eggs_eggs() { let allergies = Allergies::new(1); assert!(allergies.is_allergic_to(&Allergen::Eggs)) @@ -17,7 +15,6 @@ fn allergic_only_to_eggs_eggs() { #[test] #[ignore] - fn allergic_to_eggs_and_something_else_eggs() { let allergies = Allergies::new(3); assert!(allergies.is_allergic_to(&Allergen::Eggs)) @@ -25,7 +22,6 @@ fn allergic_to_eggs_and_something_else_eggs() { #[test] #[ignore] - fn allergic_to_something_but_not_eggs_eggs() { let allergies = Allergies::new(2); assert!(!allergies.is_allergic_to(&Allergen::Eggs)) @@ -33,7 +29,6 @@ fn allergic_to_something_but_not_eggs_eggs() { #[test] #[ignore] - fn allergic_to_everything_eggs() { let allergies = Allergies::new(255); assert!(allergies.is_allergic_to(&Allergen::Eggs)) @@ -41,7 +36,6 @@ fn allergic_to_everything_eggs() { #[test] #[ignore] - fn not_allergic_to_anything_peanuts() { let allergies = Allergies::new(0); assert!(!allergies.is_allergic_to(&Allergen::Peanuts)) @@ -49,7 +43,6 @@ fn not_allergic_to_anything_peanuts() { #[test] #[ignore] - fn allergic_only_to_peanuts_peanuts() { let allergies = Allergies::new(2); assert!(allergies.is_allergic_to(&Allergen::Peanuts)) @@ -57,7 +50,6 @@ fn allergic_only_to_peanuts_peanuts() { #[test] #[ignore] - fn allergic_to_peanuts_and_something_else_peanuts() { let allergies = Allergies::new(7); assert!(allergies.is_allergic_to(&Allergen::Peanuts)) @@ -65,7 +57,6 @@ fn allergic_to_peanuts_and_something_else_peanuts() { #[test] #[ignore] - fn allergic_to_something_but_not_peanuts_peanuts() { let allergies = Allergies::new(5); assert!(!allergies.is_allergic_to(&Allergen::Peanuts)) @@ -73,7 +64,6 @@ fn allergic_to_something_but_not_peanuts_peanuts() { #[test] #[ignore] - fn allergic_to_everything_peanuts() { let allergies = Allergies::new(255); assert!(allergies.is_allergic_to(&Allergen::Peanuts)) @@ -81,7 +71,6 @@ fn allergic_to_everything_peanuts() { #[test] #[ignore] - fn not_allergic_to_anything_shellfish() { let allergies = Allergies::new(0); assert!(!allergies.is_allergic_to(&Allergen::Shellfish)) @@ -89,7 +78,6 @@ fn not_allergic_to_anything_shellfish() { #[test] #[ignore] - fn allergic_only_to_shellfish_shellfish() { let allergies = Allergies::new(4); assert!(allergies.is_allergic_to(&Allergen::Shellfish)) @@ -97,7 +85,6 @@ fn allergic_only_to_shellfish_shellfish() { #[test] #[ignore] - fn allergic_to_shellfish_and_something_else_shellfish() { let allergies = Allergies::new(14); assert!(allergies.is_allergic_to(&Allergen::Shellfish)) @@ -105,7 +92,6 @@ fn allergic_to_shellfish_and_something_else_shellfish() { #[test] #[ignore] - fn allergic_to_something_but_not_shellfish_shellfish() { let allergies = Allergies::new(10); assert!(!allergies.is_allergic_to(&Allergen::Shellfish)) @@ -113,7 +99,6 @@ fn allergic_to_something_but_not_shellfish_shellfish() { #[test] #[ignore] - fn allergic_to_everything_shellfish() { let allergies = Allergies::new(255); assert!(allergies.is_allergic_to(&Allergen::Shellfish)) @@ -121,7 +106,6 @@ fn allergic_to_everything_shellfish() { #[test] #[ignore] - fn not_allergic_to_anything_strawberries() { let allergies = Allergies::new(0); assert!(!allergies.is_allergic_to(&Allergen::Strawberries)) @@ -129,7 +113,6 @@ fn not_allergic_to_anything_strawberries() { #[test] #[ignore] - fn allergic_only_to_strawberries_strawberries() { let allergies = Allergies::new(8); assert!(allergies.is_allergic_to(&Allergen::Strawberries)) @@ -137,7 +120,6 @@ fn allergic_only_to_strawberries_strawberries() { #[test] #[ignore] - fn allergic_to_strawberries_and_something_else_strawberries() { let allergies = Allergies::new(28); assert!(allergies.is_allergic_to(&Allergen::Strawberries)) @@ -145,7 +127,6 @@ fn allergic_to_strawberries_and_something_else_strawberries() { #[test] #[ignore] - fn allergic_to_something_but_not_strawberries_strawberries() { let allergies = Allergies::new(20); assert!(!allergies.is_allergic_to(&Allergen::Strawberries)) @@ -153,7 +134,6 @@ fn allergic_to_something_but_not_strawberries_strawberries() { #[test] #[ignore] - fn allergic_to_everything_strawberries() { let allergies = Allergies::new(255); assert!(allergies.is_allergic_to(&Allergen::Strawberries)) @@ -161,7 +141,6 @@ fn allergic_to_everything_strawberries() { #[test] #[ignore] - fn not_allergic_to_anything_tomatoes() { let allergies = Allergies::new(0); assert!(!allergies.is_allergic_to(&Allergen::Tomatoes)) @@ -169,7 +148,6 @@ fn not_allergic_to_anything_tomatoes() { #[test] #[ignore] - fn allergic_only_to_tomatoes_tomatoes() { let allergies = Allergies::new(16); assert!(allergies.is_allergic_to(&Allergen::Tomatoes)) @@ -177,7 +155,6 @@ fn allergic_only_to_tomatoes_tomatoes() { #[test] #[ignore] - fn allergic_to_tomatoes_and_something_else_tomatoes() { let allergies = Allergies::new(56); assert!(allergies.is_allergic_to(&Allergen::Tomatoes)) @@ -185,7 +162,6 @@ fn allergic_to_tomatoes_and_something_else_tomatoes() { #[test] #[ignore] - fn allergic_to_something_but_not_tomatoes_tomatoes() { let allergies = Allergies::new(40); assert!(!allergies.is_allergic_to(&Allergen::Tomatoes)) @@ -193,7 +169,6 @@ fn allergic_to_something_but_not_tomatoes_tomatoes() { #[test] #[ignore] - fn allergic_to_everything_tomatoes() { let allergies = Allergies::new(255); assert!(allergies.is_allergic_to(&Allergen::Tomatoes)) @@ -201,7 +176,6 @@ fn allergic_to_everything_tomatoes() { #[test] #[ignore] - fn not_allergic_to_anything_chocolate() { let allergies = Allergies::new(0); assert!(!allergies.is_allergic_to(&Allergen::Chocolate)) @@ -209,7 +183,6 @@ fn not_allergic_to_anything_chocolate() { #[test] #[ignore] - fn allergic_only_to_chocolate_chocolate() { let allergies = Allergies::new(32); assert!(allergies.is_allergic_to(&Allergen::Chocolate)) @@ -217,7 +190,6 @@ fn allergic_only_to_chocolate_chocolate() { #[test] #[ignore] - fn allergic_to_chocolate_and_something_else_chocolate() { let allergies = Allergies::new(112); assert!(allergies.is_allergic_to(&Allergen::Chocolate)) @@ -225,7 +197,6 @@ fn allergic_to_chocolate_and_something_else_chocolate() { #[test] #[ignore] - fn allergic_to_something_but_not_chocolate_chocolate() { let allergies = Allergies::new(80); assert!(!allergies.is_allergic_to(&Allergen::Chocolate)) @@ -233,7 +204,6 @@ fn allergic_to_something_but_not_chocolate_chocolate() { #[test] #[ignore] - fn allergic_to_everything_chocolate() { let allergies = Allergies::new(255); assert!(allergies.is_allergic_to(&Allergen::Chocolate)) @@ -241,7 +211,6 @@ fn allergic_to_everything_chocolate() { #[test] #[ignore] - fn not_allergic_to_anything_pollen() { let allergies = Allergies::new(0); assert!(!allergies.is_allergic_to(&Allergen::Pollen)) @@ -249,7 +218,6 @@ fn not_allergic_to_anything_pollen() { #[test] #[ignore] - fn allergic_only_to_pollen_pollen() { let allergies = Allergies::new(64); assert!(allergies.is_allergic_to(&Allergen::Pollen)) @@ -257,7 +225,6 @@ fn allergic_only_to_pollen_pollen() { #[test] #[ignore] - fn allergic_to_pollen_and_something_else_pollen() { let allergies = Allergies::new(224); assert!(allergies.is_allergic_to(&Allergen::Pollen)) @@ -265,7 +232,6 @@ fn allergic_to_pollen_and_something_else_pollen() { #[test] #[ignore] - fn allergic_to_something_but_not_pollen_pollen() { let allergies = Allergies::new(160); assert!(!allergies.is_allergic_to(&Allergen::Pollen)) @@ -273,7 +239,6 @@ fn allergic_to_something_but_not_pollen_pollen() { #[test] #[ignore] - fn allergic_to_everything_pollen() { let allergies = Allergies::new(255); assert!(allergies.is_allergic_to(&Allergen::Pollen)) @@ -281,7 +246,6 @@ fn allergic_to_everything_pollen() { #[test] #[ignore] - fn not_allergic_to_anything_cats() { let allergies = Allergies::new(0); assert!(!allergies.is_allergic_to(&Allergen::Cats)) @@ -289,7 +253,6 @@ fn not_allergic_to_anything_cats() { #[test] #[ignore] - fn allergic_only_to_cats_cats() { let allergies = Allergies::new(128); assert!(allergies.is_allergic_to(&Allergen::Cats)) @@ -297,7 +260,6 @@ fn allergic_only_to_cats_cats() { #[test] #[ignore] - fn allergic_to_cats_and_something_else_cats() { let allergies = Allergies::new(192); assert!(allergies.is_allergic_to(&Allergen::Cats)) @@ -305,7 +267,6 @@ fn allergic_to_cats_and_something_else_cats() { #[test] #[ignore] - fn allergic_to_something_but_not_cats_cats() { let allergies = Allergies::new(64); assert!(!allergies.is_allergic_to(&Allergen::Cats)) @@ -313,7 +274,6 @@ fn allergic_to_something_but_not_cats_cats() { #[test] #[ignore] - fn allergic_to_everything_cats() { let allergies = Allergies::new(255); assert!(allergies.is_allergic_to(&Allergen::Cats))