File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ const BUTTON_SELECTOR = '.primary.button'
33const RESET_SELECTOR = '.negative.button'
44const PROGRESS_SELECTOR = '#progress'
55const RESPONSE_MSG = 'You must give a response'
6- const questionSelector = num => `.card:nth-child( ${ num } ) `
6+ const questionSelector = num => `#question_ ${ num - 1 } `
77
88module . exports = {
99 data,
Original file line number Diff line number Diff line change @@ -40,9 +40,9 @@ describe('Quiz', () => {
4040 client . expect . element ( questionSelector ( 1 ) )
4141 . to . be . visible
4242 client . expect . element ( questionSelector ( 2 ) )
43- . to . not . be . visible
43+ . to . not . be . present
4444 client . expect . element ( questionSelector ( 3 ) )
45- . to . not . be . visible
45+ . to . not . be . present
4646 } )
4747
4848 it ( 'should display description of the question' , ( client ) => {
@@ -81,7 +81,7 @@ describe('Quiz', () => {
8181
8282 it ( 'should display the next question' , ( client ) => {
8383 client . expect . element ( questionSelector ( 1 ) )
84- . to . not . be . visible
84+ . to . not . be . present
8585 client . expect . element ( questionSelector ( 2 ) )
8686 . to . be . visible
8787 } )
@@ -102,7 +102,7 @@ describe('Quiz', () => {
102102
103103 it ( 'should display the last non answered question' , ( client ) => {
104104 client . expect . element ( questionSelector ( 1 ) )
105- . to . not . be . visible
105+ . to . not . be . present
106106 client . expect . element ( questionSelector ( 2 ) )
107107 . to . be . visible
108108 } )
@@ -120,7 +120,7 @@ describe('Quiz', () => {
120120 client . expect . element ( questionSelector ( 1 ) )
121121 . to . be . visible
122122 client . expect . element ( questionSelector ( 2 ) )
123- . to . not . be . visible
123+ . to . not . be . present
124124 } )
125125 } )
126126} )
You can’t perform that action at this time.
0 commit comments