@Test
void writer() throws IOException {

    var writer = mock(Writer.class);
    FileObject object = when(mock(FileObject.class).openWriter()).thenReturn(writer).getMock();
    when(filer.createResource(any(), any(), any())).thenReturn(object);
    
    assertEquals(writer, yaml.writer());
    verify(filer).createResource(StandardLocation.CLASS_OUTPUT, "", "plugin.yml");
    verify(object).openWriter();
}