### Question:
LessCompilerScriptService implements ScriptService { public ColorTheme getColorThemeFromSkinFile(String filename) { try { return lessColorThemeConverter.getColorThemeFromSkinFile(filename, false); } catch (LESSCompilerException e) { return new ColorTheme(); } }  String compileSkinFile(String fileName); String compileSkinFile(String fileName, boolean force); String compileSkinFile(String fileName, String skin); String compileSkinFile(String fileName, String skin, boolean force); ColorTheme getColorThemeFromSkinFile(String filename); ColorTheme getColorThemeFromSkinFile(String filename, String skin); boolean clearCache(); boolean clearCacheFromColorTheme(String colorTheme); boolean clearCacheFromSkin(String skin);  }### Answer:
@Test public void getColorThemeFromSkinFile() throws Exception { mocker.getComponentUnderTest().getColorThemeFromSkinFile("style.less"); verify(lessColorThemeConverter).getColorThemeFromSkinFile("style.less", false); }
@Test public void getColorThemeFromSkinFileWithOtherSkin() throws Exception { mocker.getComponentUnderTest().getColorThemeFromSkinFile("style.less", "flamingo"); verify(lessColorThemeConverter).getColorThemeFromSkinFile("style.less", "flamingo", false); }
@Test public void getColorThemeFromSkinFileWithException() throws Exception { Exception exception = new LESSCompilerException("Exception with LESS", null); when(lessColorThemeConverter.getColorThemeFromSkinFile("style.less", false)).thenThrow(exception); ColorTheme result = mocker.getComponentUnderTest().getColorThemeFromSkinFile("style.less"); assertEquals(0, result.size()); }
@Test public void getColorThemeFromSkinFileWithOtherSkinAndException() throws Exception { Exception exception = new LESSCompilerException("Exception with LESS", null); when(lessColorThemeConverter.getColorThemeFromSkinFile("style.less", "flamingo", false)).thenThrow(exception); ColorTheme result = mocker.getComponentUnderTest().getColorThemeFromSkinFile("style.less", "flamingo"); assertEquals(0, result.size()); }