@Override
  public void clear(int x, int y) {
    pixels[getIndex(x, y)] = Pixel.WHITE;
  }
@Test
  void testClear() {
    try {
      var field = FrameBuffer.class.getDeclaredField("pixels");
      var pixels = new Pixel[FrameBuffer.HEIGHT * FrameBuffer.WIDTH];
      Arrays.fill(pixels, Pixel.WHITE);
      pixels[0] = Pixel.BLACK;
      var frameBuffer = new FrameBuffer();
      field.setAccessible(true);
      field.set(frameBuffer, pixels);
      frameBuffer.clear(0, 0);
      assertEquals(Pixel.WHITE, frameBuffer.getPixels()[0]);
    } catch (NoSuchFieldException | IllegalAccessException e) {
      fail("Fail to modify field access.");
    }
  }