### Question:
MyBenchmark { @Benchmark public List<String> fizzbuzz() { return IntStream.rangeClosed(1, 100) .mapToObj(i -> { if (i % 15 == 0) { return "FizzBuzz"; } else if (i % 3 == 0) { return "Fizz"; } else if (i % 5 == 0) { return "Buzz"; } return String.valueOf(i); }) .collect(Collectors.toList()); }  @Benchmark List<String> fizzbuzz();  }### Answer:
@Test void fizzbuzz() { final MyBenchmark benchmark = new MyBenchmark(); final List<String> list = benchmark.fizzbuzz(); Assertions.assertAll(() -> { Assertions.assertEquals(100, list.size()); Assertions.assertEquals("1", list.get(0)); Assertions.assertEquals("2", list.get(1)); Assertions.assertEquals("Fizz", list.get(2)); Assertions.assertEquals("4", list.get(3)); Assertions.assertEquals("Buzz", list.get(4)); Assertions.assertEquals("Fizz", list.get(5)); Assertions.assertEquals("7", list.get(6)); Assertions.assertEquals("8", list.get(7)); Assertions.assertEquals("Fizz", list.get(8)); Assertions.assertEquals("Buzz", list.get(9)); Assertions.assertEquals("11", list.get(10)); Assertions.assertEquals("Fizz", list.get(11)); Assertions.assertEquals("13", list.get(12)); Assertions.assertEquals("14", list.get(13)); Assertions.assertEquals("FizzBuzz", list.get(14)); }); }