your way out • You *don’t* start by creating your domain/ object model Wednesday, September 25, 13 When you need an object, you add it. It happens “organically”
write the code - Green-field or brown-field Here is the deal: - Think of it like your “game plan” that actually serves as driving out the features you need and serves as a test framework and documentation
You are a professional • You don’t want to go off on tangents • You want to go home at night • It is fun! Wednesday, September 25, 13 - Tests stay up to date, docs do not - Gives you documentation
I want [feature] So that [benefit] Acceptance Criteria: (presented as Scenarios) Scenario 1: Title Given [context] And [some more context]... When [event] Then [outcome] And [another outcome]... Scenario 2: ... Wednesday, September 25, 13 BDD provides the structure of a story Keith Gaddis taught a BDD class and stated “If you can’t fill out the narrative, then you don’t know what you are doing enough to write the code”
sky” idea - this works - used by myself at Wellmatch. You would never do this an regret it. Every time ... - used by many other badass shops (Hashrocket, Pivotal, Thoghtbot, Carbon5, etc.) - this is just one way to work, but it does work
all rolled into one format.” • Gherkin - plain text DSL • Makes the requests, gets the results, you assert on it Wednesday, September 25, 13 - Cucumber makes the requests and gets the results and you assert on it. This is not a tools talk or a BDD theory talk, but a “flow” talk
really too high level to have alone, they are better than nothing but they might hide crap underneath - Good Smoke test - Happy path testing - We usually have the UI done for us already, we just have to go plug it in. So this really is the flow, besides more rspec for business logic. - Generally accepted practice to not test controller. Keep them light,
do User.make(:email => '[email protected]', :password => 'caplin') end it "signs me in" do visit '/sessions/new' within("#session") do fill_in 'Login', :with => '[email protected]' fill_in 'Password', :with => 'password' end click_link 'Sign in' expect(page).to have_content 'Success' end end Wednesday, September 25, 13 - turnip, spinich, straight selenium
Rails Dev • Sr. QA • 2 (less Sr.) QA • Great team, WFH, pair-programming • Healthcare Cost-Transparency Software Wednesday, September 25, 13 not some boring ass Accounting software, maybe this will make people’s lives better?