@@ -3725,19 +3725,16 @@ describe('utils', () => {
3725
3725
} ) ;
3726
3726
3727
3727
describe ( "setTimezone" , ( ) => {
3728
- let isTimezoneArgPassed ;
3729
3728
let processStub ;
3730
3729
let loggerStub ;
3731
3730
let syncCliLoggerStub ;
3732
3731
beforeEach ( ( ) => {
3733
- isTimezoneArgPassed = sinon . stub ( utils , 'isTimezoneArgPassed' ) ;
3734
3732
processStub = sinon . stub ( process , 'exit' ) ;
3735
3733
loggerStub = sinon . stub ( winstonLogger , 'error' ) ;
3736
3734
syncCliLoggerStub = sinon . stub ( syncCliLogger , 'info' ) ;
3737
3735
} ) ;
3738
3736
3739
3737
afterEach ( ( ) => {
3740
- isTimezoneArgPassed . restore ( ) ;
3741
3738
processStub . restore ( ) ;
3742
3739
loggerStub . restore ( ) ;
3743
3740
syncCliLoggerStub . restore ( ) ;
@@ -3751,7 +3748,6 @@ describe('utils', () => {
3751
3748
let args = {
3752
3749
timezone : "New_York"
3753
3750
} ;
3754
- isTimezoneArgPassed . returns ( true ) ;
3755
3751
utils . setTimezone ( bsConfig , args ) ;
3756
3752
expect ( bsConfig . run_settings . timezone ) . to . eq ( "New_York" ) ;
3757
3753
} ) ;
@@ -3763,7 +3759,6 @@ describe('utils', () => {
3763
3759
}
3764
3760
}
3765
3761
let args = { } ;
3766
- isTimezoneArgPassed . returns ( true ) ;
3767
3762
utils . setTimezone ( bsConfig , args ) ;
3768
3763
expect ( bsConfig . run_settings . timezone ) . to . eq ( undefined ) ;
3769
3764
} ) ;
@@ -3777,7 +3772,6 @@ describe('utils', () => {
3777
3772
let args = {
3778
3773
timezone : "xyz"
3779
3774
} ;
3780
- isTimezoneArgPassed . returns ( true ) ;
3781
3775
utils . setTimezone ( bsConfig , args ) ;
3782
3776
expect ( bsConfig . run_settings . timezone ) . to . eq ( undefined ) ;
3783
3777
sinon . assert . calledOnceWithExactly ( loggerStub , "Invalid timezone = xyz" ) ;
@@ -3792,7 +3786,6 @@ describe('utils', () => {
3792
3786
}
3793
3787
}
3794
3788
let args = { } ;
3795
- isTimezoneArgPassed . returns ( false ) ;
3796
3789
utils . setTimezone ( bsConfig , args ) ;
3797
3790
expect ( bsConfig . run_settings . timezone ) . to . eq ( undefined ) ;
3798
3791
sinon . assert . calledOnceWithExactly ( loggerStub , "Invalid timezone = abc" ) ;
@@ -3807,7 +3800,6 @@ describe('utils', () => {
3807
3800
}
3808
3801
}
3809
3802
let args = { } ;
3810
- isTimezoneArgPassed . returns ( false ) ;
3811
3803
utils . setTimezone ( bsConfig , args ) ;
3812
3804
expect ( bsConfig . run_settings . timezone ) . to . eq ( "London" ) ;
3813
3805
} ) ;
@@ -3817,7 +3809,6 @@ describe('utils', () => {
3817
3809
run_settings : { }
3818
3810
}
3819
3811
let args = { } ;
3820
- isTimezoneArgPassed . returns ( false ) ;
3821
3812
utils . setTimezone ( bsConfig , args ) ;
3822
3813
expect ( bsConfig . run_settings . timezone ) . to . eq ( undefined ) ;
3823
3814
} ) ;
0 commit comments