Skip to content

Commit

Permalink
Add simple titleMatches test and a skeleton for another test
Browse files Browse the repository at this point in the history
  • Loading branch information
arnlaugsson committed Oct 25, 2016
1 parent 3a3c2b4 commit 9e79d69
Showing 1 changed file with 25 additions and 0 deletions.
25 changes: 25 additions & 0 deletions src/selenium/java/is/ru/arnlaugsson/chuck_joke/TestChuckWeb.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
package is.ru.arnlaugsson.chuck_joke;

import static org.junit.Assert.assertEquals;
import org.junit.Test;

public class TestChuckWeb extends SeleniumTestWrapper {
@Test
public void titleMatches() {
driver.get(baseUrl);
assertEquals("Chuck Norris Jokes", driver.getTitle());
}

@Test
public void assertUpdatingNameChangesSpecificJoke() {
driver.get(baseUrl + "/config.html");
/*
1. Fill in some name (first name, last name)
2. Submit form.
3. Assert that form notifies of success ("Name set as: ...")
4. Navigate to page to get specific Joke
5. Enter a specific joke number
6. Assert the name is used in the joke.
*/
}
}

0 comments on commit 9e79d69

Please sign in to comment.