@@ -4,6 +4,7 @@ casper.test.begin('todomvc', 63, function (test) {
44 casper
55 . start ( 'examples/todomvc/index.html' )
66 . then ( function ( ) {
7+ this . viewport ( 1000 , 1000 ) // for appearing destroy buttons by mouse hover
78 test . assertNotVisible ( '.main' , '.main should be hidden' )
89 test . assertNotVisible ( '.footer' , '.footer should be hidden' )
910 test . assertElementCount ( '.filters .selected' , 1 , 'should have one filter selected' )
@@ -90,6 +91,9 @@ casper.test.begin('todomvc', 63, function (test) {
9091
9192 // remove a completed item --------------------------------------------
9293
94+ . then ( function ( ) {
95+ this . mouse . move ( '.todo:nth-child(1)' )
96+ } )
9397 . thenClick ( '.todo:nth-child(1) .destroy' , function ( ) {
9498 test . assertElementCount ( '.todo' , 4 , 'should have 4 items now' )
9599 test . assertElementCount ( '.todo.completed' , 2 , 'should have 2 item completed' )
@@ -98,6 +102,9 @@ casper.test.begin('todomvc', 63, function (test) {
98102
99103 // remove a incompleted item ------------------------------------------
100104
105+ . then ( function ( ) {
106+ this . mouse . move ( '.todo:nth-child(2)' )
107+ } )
101108 . thenClick ( '.todo:nth-child(2) .destroy' , function ( ) {
102109 test . assertElementCount ( '.todo' , 3 , 'should have 3 items now' )
103110 test . assertElementCount ( '.todo.completed' , 2 , 'should have 2 item completed' )
0 commit comments