@@ -122,35 +122,35 @@ TEST_CASE("Adds secret vector ingredient", "[task_3]") {
122122 REQUIRE (myList == expected);
123123}
124124
125- TEST_CASE (" scaledQuantities : scales up correctly" , " [task_4]" ) {
125+ TEST_CASE (" scaleRecipe : scales up correctly" , " [task_4]" ) {
126126 const std::vector<double > input{0.5 , 250 , 150 , 3 , 0.5 };
127127 int portions{6 };
128128 std::vector<double > expected{1.5 , 750 , 450 , 9 , 1.5 };
129- std::vector<double > scaled{scaledQuantities (input, portions)};
129+ std::vector<double > scaled{scaleRecipe (input, portions)};
130130 REQUIRE_VECTOR_APROX_EQUAL (expected, scaled, 0.0001 )
131131}
132132
133- TEST_CASE (" scaledQuantities : scales up correctly (2)" , " [task_4]" ) {
133+ TEST_CASE (" scaleRecipe : scales up correctly (2)" , " [task_4]" ) {
134134 const std::vector<double > input{0.6 , 300 , 1 , 0.5 , 50 , 0.1 , 100 };
135135 int portions{3 };
136136 std::vector<double > expected{0.9 , 450 , 1.5 , 0.75 , 75 , 0.15 , 150 };
137- std::vector<double > scaled{scaledQuantities (input, portions)};
137+ std::vector<double > scaled{scaleRecipe (input, portions)};
138138 REQUIRE_VECTOR_APROX_EQUAL (expected, scaled, 0.0001 )
139139}
140140
141- TEST_CASE (" scaledQuantities : scales down correctly" , " [task_4]" ) {
141+ TEST_CASE (" scaleRecipe : scales down correctly" , " [task_4]" ) {
142142 const std::vector<double > input{0.5 , 250 , 150 , 3 , 0.5 };
143143 int portions{1 };
144144 std::vector<double > expected{0.25 , 125 , 75 , 1.5 , 0.25 };
145- std::vector<double > scaled{scaledQuantities (input, portions)};
145+ std::vector<double > scaled{scaleRecipe (input, portions)};
146146 REQUIRE_VECTOR_APROX_EQUAL (expected, scaled, 0.0001 )
147147}
148148
149- TEST_CASE (" scaledQuantities : empty recipe" , " [task_4]" ) {
149+ TEST_CASE (" scaleRecipe : empty recipe" , " [task_4]" ) {
150150 const std::vector<double > input{};
151151 int portions{100 };
152152 std::vector<double > expected{};
153- std::vector<double > scaled{scaledQuantities (input, portions)};
153+ std::vector<double > scaled{scaleRecipe (input, portions)};
154154 REQUIRE_VECTOR_APROX_EQUAL (expected, scaled, 0.0001 )
155155}
156156
0 commit comments