use of net.sf.latexdraw.util.SystemUtils in project latexdraw by arnobl.
the class ExportTemplateTest method commonCanDoFixture.
@Override
protected void commonCanDoFixture() {
final SystemUtils utils = Mockito.mock(SystemUtils.class);
Mockito.when(utils.getPathTemplatesDirUser()).thenReturn("");
SystemUtils.setSingleton(utils);
svgGen = Mockito.mock(SVGDocumentGenerator.class);
ui = Mockito.mock(JfxUI.class);
statusWidget = Mockito.mock(Label.class);
progressBar = Mockito.mock(ProgressBar.class);
templatesPane = Mockito.mock(Pane.class);
alertName = Mockito.mock(Alert.class);
inputName = Mockito.mock(TextInputDialog.class);
cmd = new ExportTemplate(templatesPane, svgGen, ui, progressBar, statusWidget, alertName, inputName);
}
use of net.sf.latexdraw.util.SystemUtils in project latexdraw by arnobl.
the class NewDrawingTest method commonCanDoFixture.
@Override
protected void commonCanDoFixture() {
final SystemUtils utils = Mockito.mock(SystemUtils.class);
Mockito.when(utils.getPathTemplatesDirUser()).thenReturn("");
SystemUtils.setSingleton(utils);
ui = Mockito.mock(JfxUI.class);
statusWidget = Mockito.mock(Label.class);
progressBar = Mockito.mock(ProgressBar.class);
mainstage = Mockito.mock(Stage.class);
file = Mockito.mock(File.class);
modifiedAlert = Mockito.mock(Alert.class);
openSaveManager = Mockito.mock(OpenSaver.class);
fileChooser = Mockito.mock(FileChooser.class);
currentFolder = Optional.empty();
cmd = new NewDrawing(file, openSaveManager, progressBar, statusWidget, ui, fileChooser, currentFolder, mainstage, modifiedAlert);
}
use of net.sf.latexdraw.util.SystemUtils in project latexdraw by arnobl.
the class SaveDrawingTest method commonCanDoFixture.
@Override
protected void commonCanDoFixture() {
final SystemUtils utils = Mockito.mock(SystemUtils.class);
Mockito.when(utils.getPathTemplatesDirUser()).thenReturn("");
SystemUtils.setSingleton(utils);
ui = Mockito.mock(JfxUI.class);
statusWidget = Mockito.mock(Label.class);
progressBar = Mockito.mock(ProgressBar.class);
mainstage = Mockito.mock(Stage.class);
file = Mockito.mock(File.class);
modifiedAlert = Mockito.mock(Alert.class);
openSaveManager = Mockito.mock(OpenSaver.class);
fileChooser = Mockito.mock(FileChooser.class);
currentFolder = Optional.empty();
injector = Mockito.mock(Injector.class);
prefService = Mockito.mock(PreferencesService.class);
Mockito.when(injector.getInstance(PreferencesService.class)).thenReturn(prefService);
cmd = new SaveDrawing(true, true, currentFolder, fileChooser, injector, file, openSaveManager, progressBar, ui, statusWidget, mainstage, modifiedAlert);
}
use of net.sf.latexdraw.util.SystemUtils in project latexdraw by arnobl.
the class LoadDrawingTest method commonCanDoFixture.
@Override
protected void commonCanDoFixture() {
final SystemUtils utils = Mockito.mock(SystemUtils.class);
Mockito.when(utils.getPathTemplatesDirUser()).thenReturn("");
SystemUtils.setSingleton(utils);
ui = Mockito.mock(JfxUI.class);
statusWidget = Mockito.mock(Label.class);
progressBar = Mockito.mock(ProgressBar.class);
mainstage = Mockito.mock(Stage.class);
file = Mockito.mock(File.class);
modifiedAlert = Mockito.mock(Alert.class);
openSaveManager = Mockito.mock(OpenSaver.class);
fileChooser = Mockito.mock(FileChooser.class);
currentFolder = Optional.empty();
cmd = new LoadDrawing(file, openSaveManager, progressBar, statusWidget, ui, fileChooser, currentFolder, mainstage, modifiedAlert);
}
Aggregations