@@ -18,7 +18,7 @@ describe('Timer Functionality', () => {
1818 cy . getWorkoutControlState ( 'pause' ) . should ( 'be.enabled' )
1919 cy . getWorkoutControlState ( 'skip' ) . should ( 'be.enabled' )
2020
21- cy . getExerciseItems ( ) . first ( ) . should ( 'have.class' , 'current' )
21+ cy . getExerciseItem ( 0 ) . should ( 'have.class' , 'current' )
2222 } )
2323
2424 it ( 'should pause and resume the timer' , ( ) => {
@@ -59,8 +59,8 @@ describe('Timer Functionality', () => {
5959 cy . getTimerDisplay ( ) . should ( 'contain' , '0:02' )
6060 cy . get ( '#progressText' ) . should ( 'contain' , 'Exercise 2 of 6' )
6161
62- cy . getExerciseItems ( ) . first ( ) . should ( 'have.class' , 'completed' )
63- cy . getExerciseItems ( ) . eq ( 1 ) . should ( 'have.class' , 'current' )
62+ cy . getExerciseItem ( 0 ) . should ( 'have.class' , 'completed' )
63+ cy . getExerciseItem ( 1 ) . should ( 'have.class' , 'current' )
6464 } )
6565
6666 it ( 'should reset the workout' , ( ) => {
@@ -76,7 +76,7 @@ describe('Timer Functionality', () => {
7676 cy . getWorkoutControlState ( 'pause' ) . should ( 'be.disabled' )
7777 cy . getWorkoutControlState ( 'skip' ) . should ( 'be.disabled' )
7878
79- cy . getExerciseItems ( ) . first ( ) . should ( 'have.class' , 'current' )
79+ cy . getExerciseItem ( 0 ) . should ( 'have.class' , 'current' )
8080 } )
8181
8282 it ( 'should automatically advance through exercises' , ( ) => {
@@ -124,14 +124,14 @@ describe('Timer Functionality', () => {
124124 cy . clickWorkoutControl ( 'start' )
125125
126126 cy . clickWorkoutControl ( 'skip' )
127- cy . getExerciseItems ( ) . first ( ) . should ( 'have.class' , 'completed' )
127+ cy . getExerciseItem ( 0 ) . should ( 'have.class' , 'completed' )
128128
129129 cy . clickWorkoutControl ( 'skip' )
130- cy . getExerciseItems ( ) . eq ( 1 ) . should ( 'have.class' , 'completed' )
130+ cy . getExerciseItem ( 1 ) . should ( 'have.class' , 'completed' )
131131
132132 cy . clickWorkoutControl ( 'skip' )
133- cy . getExerciseItems ( ) . eq ( 2 ) . should ( 'have.class' , 'completed' )
134- cy . getExerciseItems ( ) . eq ( 3 ) . should ( 'have.class' , 'current' )
133+ cy . getExerciseItem ( 2 ) . should ( 'have.class' , 'completed' )
134+ cy . getExerciseItem ( 3 ) . should ( 'have.class' , 'current' )
135135 } )
136136
137137 it ( 'should handle timer countdown accuracy' , ( ) => {
0 commit comments