dialogFixture.button("ButtonNotStart").requireDisabled();
dialogFixture.button("ButtonNotStart").requireText(
"Ikke startet produksjon");
JTableFixture tableFixture = dialogFixture
.table(TableEnum.TABLEPRODUCTIONTAKSTOL.getTableName());
assertEquals("Startet", tableFixture.target.getColumnName(8));
tableFixture.cell(row(0).column(1)).click();
Produceable order = takstolProductionViewHandler.getSelectedObject();
int index = 0;
while (order.getProbability() != 100 || order.getProduced() != null) {
index++;
tableFixture.cell(row(index).column(1)).click();
order = takstolProductionViewHandler.getSelectedObject();
}
String content = tableFixture.cell(row(index).column(8)).value();
if (content.equalsIgnoreCase("---")) {
dialogFixture.button("ButtonStart").requireEnabled();
dialogFixture.button("ButtonStart").click();
dialogFixture.button("ButtonStart").requireDisabled();
tableFixture.cell(row(index).column(1)).click();
dialogFixture.button("ButtonStart").requireDisabled();
dialogFixture.button("ButtonNotStart").requireEnabled();
} else {
dialogFixture.button("ButtonNotStart").requireEnabled();
dialogFixture.button("ButtonNotStart").click();
dialogFixture.button("ButtonNotStart").requireDisabled();
tableFixture.cell(row(index).column(1)).click();
dialogFixture.button("ButtonNotStart").requireDisabled();
dialogFixture.button("ButtonStart").requireEnabled();
}
}