File tree Expand file tree Collapse file tree 4 files changed +187
-318
lines changed Expand file tree Collapse file tree 4 files changed +187
-318
lines changed Original file line number Diff line number Diff line change @@ -300,7 +300,7 @@ Note that **Highway** uses modern features because we wanted it to be *modern*.
300300
301301## Roadmap
302302
303- - [ ] Unit Tests
303+ - [ ] More Unit Tests
304304- [ ] More Examples
305305
306306## Releases
Original file line number Diff line number Diff line change 4242 "babel-preset-env" : " ^1.6.1" ,
4343 "chai" : " ^4.1.2" ,
4444 "chai-as-promised" : " ^7.1.1" ,
45- "chai-fetch-mock" : " ^2.0.0" ,
4645 "compression-webpack-plugin" : " ^1.1.11" ,
47- "fetch-mock" : " ^6.3.0" ,
4846 "isomorphic-fetch" : " ^2.2.1" ,
4947 "jsdom" : " ^11.7.0" ,
5048 "jsdom-global" : " ^3.0.2" ,
Original file line number Diff line number Diff line change @@ -18,23 +18,26 @@ import Highway from '../src/index';
1818// DOM
1919import Home from './dom/home' ;
2020
21- // Transition instance
22- const Transition = new Highway . Transition ( Home . page ) ;
23-
2421// Assertions
2522describe ( 'Highway.Transition' , ( ) => {
2623 it ( 'Should be an instance of `Highway.Transition`' , ( ) => {
24+ const Transition = new Highway . Transition ( Home . page ) ;
25+
2726 expect ( Transition ) . to . be . instanceof ( Highway . Transition ) ;
2827 } ) ;
2928
3029 it ( 'Should call `in` on `show`' , ( ) => {
30+ const Transition = new Highway . Transition ( Home . page ) ;
31+
3132 Transition . in = sinon . spy ( ) ;
3233 Transition . show ( ) . then ( ( ) => {
3334 expect ( Transition . in . calledOnce ) . to . equal ( true ) ;
3435 } ) ;
3536 } ) ;
3637
3738 it ( 'Should call `out` on `hide`' , ( ) => {
39+ const Transition = new Highway . Transition ( Home . page ) ;
40+
3841 Transition . out = sinon . spy ( ) ;
3942 Transition . hide ( ) . then ( ( ) => {
4043 expect ( Transition . out . calledOnce ) . to . equal ( true ) ;
You can’t perform that action at this time.
0 commit comments