MCPcopy Create free account
hub / github.com/Berkeley-CS61B/skeleton-sp23 / testProduct

Method testProduct

lab01/tests/ArithmeticTest.java:15–22  ·  view source on GitHub ↗

Performs a few arbitrary tests to see if the product method is correct

()

Source from the content-addressed store, hash-verified

13 /** Performs a few arbitrary tests to see if the product method is
14 * correct */
15 @Test
16 @Order(0)
17 @DisplayName("Test product correctness")
18 public void testProduct() {
19 assertThat(Arithmetic.product(5, 6)).isEqualTo(30);
20 assertThat(Arithmetic.product(5, -6)).isEqualTo(-30);
21 assertThat(Arithmetic.product(0, -6)).isEqualTo(0);
22 }
23
24 /** Performs a few arbitrary tests to see if the sum method is correct */
25 @Test

Callers

nothing calls this directly

Calls 1

productMethod · 0.95

Tested by

no test coverage detected