@Test void persistSketchAsSvgAndPng() { givenIssueDirectoryDoesNotExist(); sketcherDao.persistSketchAsSvgAndPng(BRANCH_NAME, ISSUE_ID, SCENARIO_SKETCH_ID, STEP_SKETCH); expectStepSketchDirectoryCreated(); expectSketchAsSvgPersisted(); expectSketchAsPngPersisted(); }
public void persistSketchAsSvgAndPng(final String branchName, final String issueId, final String scenarioSketchId, final StepSketch stepSketch) { storeSvgFile(branchName, issueId, scenarioSketchId, stepSketch); storePngFile(branchName, issueId, scenarioSketchId, stepSketch.getStepSketchId(), stepSketch.getSvgXmlString()); }
SketcherDao { public void persistSketchAsSvgAndPng(final String branchName, final String issueId, final String scenarioSketchId, final StepSketch stepSketch) { storeSvgFile(branchName, issueId, scenarioSketchId, stepSketch); storePngFile(branchName, issueId, scenarioSketchId, stepSketch.getStepSketchId(), stepSketch.getSvgXmlString()); } }
SketcherDao { public void persistSketchAsSvgAndPng(final String branchName, final String issueId, final String scenarioSketchId, final StepSketch stepSketch) { storeSvgFile(branchName, issueId, scenarioSketchId, stepSketch); storePngFile(branchName, issueId, scenarioSketchId, stepSketch.getStepSketchId(), stepSketch.getSvgXmlString()); } SketcherDao(); }
SketcherDao { public void persistSketchAsSvgAndPng(final String branchName, final String issueId, final String scenarioSketchId, final StepSketch stepSketch) { storeSvgFile(branchName, issueId, scenarioSketchId, stepSketch); storePngFile(branchName, issueId, scenarioSketchId, stepSketch.getStepSketchId(), stepSketch.getSvgXmlString()); } SketcherDao(); File getRootDirectory(); File getBranchDirectory(final String branchName); File getIssueDirectory(final String branchName, final String issueId); File getIssueFile(final String branchName, final String issueId); List<File> getIssueFiles(final String branchName); File getScenarioSketchDirectory(final String branchName, final String issueId,
			final String scenarioSketchId); File getScenarioSketchFile(final String branchName, final String issueId, final String scenarioSketchId); List<File> getScenarioSketchFiles(final String branchName, final String issueId); File getStepSketchDirectory(final String branchName, final String issueId,
			final String scenarioSketchId, final String stepSketchId); File getStepSketchXmlFile(final String branchName, final String issueId, final String scenarioSketchId,
			final String stepSketchId); File getStepSketchXmlFile(final String branchName, final String issueId,
			final String scenarioSketchId, final StepSketch stepSketch); File getStepSketchSvgFile(final String branchName, final String issueId, final String scenarioSketchId,
			final String stepSketchId); File getStepSketchImageFile(final String branchName, final String issueId, final String scenarioSketchId,
									   final String stepSketchId, final String imageFilename); List<File> getStepSketchFiles(final String branchName, final String issueId,
			final String scenarioSketchId); void persistIssue(final String branchName, final Issue issue); void persistScenarioSketch(final String branchName, final String issueId,
			final ScenarioSketch scenarioSketch); void persistStepSketch(final String branchName, final String issueId,
			final String scenarioSketchId, final StepSketch stepSketch); void persistSketchAsSvgAndPng(final String branchName, final String issueId,
			final String scenarioSketchId, final StepSketch stepSketch); void copyOriginalScreenshot(final File originalScreenshot, final String branchName, final String issueId,
			final String scenarioSketchId, final String stepSketchId); List<Issue> loadIssues(final String branchName); Issue loadIssue(final String branchName, final String issueId); List<ScenarioSketch> loadScenarioSketches(final String branchName, final String issueId); ScenarioSketch loadScenarioSketch(final String branchName, final String issueId,
			final String scenarioSketchId); List<StepSketch> loadStepSketches(final String branchName, final String issueId,
			final String scenarioSketchId); StepSketch loadStepSketch(final String branchName, final String issueId,
			final String scenarioSketchId, final String stepSketchId); }
SketcherDao { public void persistSketchAsSvgAndPng(final String branchName, final String issueId, final String scenarioSketchId, final StepSketch stepSketch) { storeSvgFile(branchName, issueId, scenarioSketchId, stepSketch); storePngFile(branchName, issueId, scenarioSketchId, stepSketch.getStepSketchId(), stepSketch.getSvgXmlString()); } SketcherDao(); File getRootDirectory(); File getBranchDirectory(final String branchName); File getIssueDirectory(final String branchName, final String issueId); File getIssueFile(final String branchName, final String issueId); List<File> getIssueFiles(final String branchName); File getScenarioSketchDirectory(final String branchName, final String issueId,
			final String scenarioSketchId); File getScenarioSketchFile(final String branchName, final String issueId, final String scenarioSketchId); List<File> getScenarioSketchFiles(final String branchName, final String issueId); File getStepSketchDirectory(final String branchName, final String issueId,
			final String scenarioSketchId, final String stepSketchId); File getStepSketchXmlFile(final String branchName, final String issueId, final String scenarioSketchId,
			final String stepSketchId); File getStepSketchXmlFile(final String branchName, final String issueId,
			final String scenarioSketchId, final StepSketch stepSketch); File getStepSketchSvgFile(final String branchName, final String issueId, final String scenarioSketchId,
			final String stepSketchId); File getStepSketchImageFile(final String branchName, final String issueId, final String scenarioSketchId,
									   final String stepSketchId, final String imageFilename); List<File> getStepSketchFiles(final String branchName, final String issueId,
			final String scenarioSketchId); void persistIssue(final String branchName, final Issue issue); void persistScenarioSketch(final String branchName, final String issueId,
			final ScenarioSketch scenarioSketch); void persistStepSketch(final String branchName, final String issueId,
			final String scenarioSketchId, final StepSketch stepSketch); void persistSketchAsSvgAndPng(final String branchName, final String issueId,
			final String scenarioSketchId, final StepSketch stepSketch); void copyOriginalScreenshot(final File originalScreenshot, final String branchName, final String issueId,
			final String scenarioSketchId, final String stepSketchId); List<Issue> loadIssues(final String branchName); Issue loadIssue(final String branchName, final String issueId); List<ScenarioSketch> loadScenarioSketches(final String branchName, final String issueId); ScenarioSketch loadScenarioSketch(final String branchName, final String issueId,
			final String scenarioSketchId); List<StepSketch> loadStepSketches(final String branchName, final String issueId,
			final String scenarioSketchId); StepSketch loadStepSketch(final String branchName, final String issueId,
			final String scenarioSketchId, final String stepSketchId); static final String SKETCHER_DIRECTORY; }