@@ -81,7 +81,7 @@ describe('demo app', function () {
81
81
} )
82
82
83
83
describe ( 'when clicking on a section from the nav bar' , function ( ) {
84
- it ( 'shows the selected section in the main area' , function ( ) {
84
+ it ( 'it shows the selected section in the main area' , function ( ) {
85
85
return app . client . isVisible ( '#windows-section' ) . should . eventually . be . true
86
86
. click ( 'button[data-section="windows"]' ) . pause ( 100 )
87
87
. waitForVisible ( '#windows-section' )
@@ -95,8 +95,8 @@ describe('demo app', function () {
95
95
} )
96
96
} )
97
97
98
- describe ( 'when a task is clicked' , function ( ) {
99
- it ( 'it expands' , function ( ) {
98
+ describe ( 'when a demo title is clicked' , function ( ) {
99
+ it ( 'it expands the demo content ' , function ( ) {
100
100
var onlyFirstVisible = Array ( 21 ) . fill ( false )
101
101
onlyFirstVisible [ 0 ] = true
102
102
@@ -105,9 +105,20 @@ describe('demo app', function () {
105
105
. click ( '.js-container-target' )
106
106
. waitForVisible ( '.toggle-content' )
107
107
. isVisible ( '.toggle-content' ) . should . eventually . deep . equal ( onlyFirstVisible )
108
+ } )
109
+ } )
110
+
111
+ describe ( 'when the app is restarted after use' , function ( ) {
112
+ it ( 'it launches at last visted section & demo' , function ( ) {
113
+ var onlyFirstVisible = Array ( 21 ) . fill ( false )
114
+ onlyFirstVisible [ 0 ] = true
115
+
116
+ return app . client . waitForVisible ( '#windows-section' )
108
117
. then ( restartApp )
109
118
. then ( function ( ) {
110
119
return app . client . waitForVisible ( '#windows-section' )
120
+ . isVisible ( '#windows-section' ) . should . eventually . be . true
121
+ . isVisible ( '.toggle-content' ) . should . eventually . deep . equal ( onlyFirstVisible )
111
122
} )
112
123
} )
113
124
} )
0 commit comments