use of com.github.noraui.application.model.demo.Article in project NoraUi by NoraUi.
the class HelloByeSteps method readBlog.
@RetryOnFailure(attempts = 3)
@Given("me any article, please. '(.*)' of '(.*)'.")
public void readBlog(String jsonArticles, String blog) throws FailureException {
Articles articles = new Articles();
articles.deserialize(jsonArticles);
for (Article article : articles) {
if ("anonymous".equals(article.getAuthor())) {
new Result.Failure<>("anonymous", "anonymous is prohibited in demo blog!!", true, this.demoPage.getCallBack());
} else {
logger.info("> " + blog);
logger.info(" > " + article.getTitle() + ": " + article.getText());
}
}
}
Aggregations