File tree Expand file tree Collapse file tree 1 file changed +14
-5
lines changed
src/js/__tests__/components Expand file tree Collapse file tree 1 file changed +14
-5
lines changed Original file line number Diff line number Diff line change @@ -25,17 +25,20 @@ describe('Test for Login Component', function () {
2525 on : function ( event , callback ) {
2626
2727 if ( event == 'did-get-redirect-request' ) {
28- callback ( {
29- event : 'did-get-redirect-request' ,
30- oldUrl : 'http://www.github.com/?code=123123123' ,
31- newUrl : 'http://www.github.com/?code=123123123'
32- } ) ;
28+ callback (
29+ 'did-get-redirect-request' ,
30+ 'http://www.github.com/?code=123123123' ,
31+ 'http://www.github.com/?code=123123123'
32+ ) ;
3333 }
3434
3535 }
3636 } ,
3737 on : function ( ) {
3838 return ;
39+ } ,
40+ close : function ( ) {
41+ return ;
3942 }
4043 } ;
4144 } ;
@@ -105,6 +108,12 @@ describe('Test for Login Component', function () {
105108 var instance = TestUtils . renderIntoDocument ( < Login /> ) ;
106109 expect ( instance . authGithub ) . toBeDefined ( ) ;
107110
111+ // Prevent testing requestGithubToken
112+ // Tested in another case
113+ instance . requestGithubToken = function ( ) {
114+ return ;
115+ } ;
116+
108117 instance . authGithub ( ) ;
109118
110119 } ) ;
You can’t perform that action at this time.
0 commit comments