@Test
public void noPlugins() throws IOException {

  System2 sys = mock(System2.class);
  Path emptyDir = temp.newFolder().toPath();
  when(sys.getProperty(SonarProperties.PROJECT_HOME)).thenReturn(emptyDir.toString());
  Main.execute(new String[]{}, sys);
  verify(sys).exit(Main.ERROR);
  assertThat(getLogs(err)).contains("Error loading plugins");
}