restCaller.postSourceDocResource("obsolete-test", "master", resource2,
false);
// edit first entry and save
new LoginWorkFlow().signIn("admin", "admin");
final EditorPage editorPage = openEditor();
editorPage.translateTargetAtRowIndex(0, "message one translated")
.approveTranslationAtRow(0);
// delete resource 2
resource2.getTextFlows().clear();
restCaller.deleteSourceDoc("obsolete-test", "master", "message2");
// remove last entry from resource 1
resource1.getTextFlows().remove(3);
restCaller.putSourceDocResource("obsolete-test", "master", "message1",
resource1, true);
final EditorPage editorPageFinal =
openEditor()
.translateTargetAtRowIndex(1, "message two translated")
.approveTranslationAtRow(1)
.translateTargetAtRowIndex(2, "translated")
.approveTranslationAtRow(2);
editorPageFinal.waitFor(new Callable<String>() {
@Override
public String call() throws Exception {
return editorPageFinal.getStatistics();
}
}, Matchers.containsString("100%"));
VersionLanguagesPage versionPage =
new BasicWorkFlow().goToPage(String.format(