☕️ Proudly built in Atlanta, GA
Tuesday, January 2, 2018
2 min read
Today while writing tests (shocking, I know), I came across an interesting and unknown (at the time) scenario. For the site, I wanted to test and make sure a certain element was showing up on the page. At the time, I was writing Behat tests to do some functionality and the tests are very simple to write, so I decided to try and create a simple test for my element. Usually this is pretty straightforward:
1Given I am on "/" #the homepage2Then I should see ".ad-block" element
1Given I am on "/"2And I wait 4 seconds
That's what I learned today! Luckily, Behat is our Behavior Driven Development testing framework, but we also use CasperJS for our testing. In fact, there were already tests written for other ads on the site. The more you know!