@@ -64,7 +64,7 @@ void main() {
6464 test ('When SDK was initialized, getToken() should return token' , () async {
6565 final completer = Completer <String >();
6666
67- Mindbox .instance.getTokens ((deviceToken) => completer.complete (deviceToken));
67+ Mindbox .instance.getToken ((deviceToken) => completer.complete (deviceToken));
6868
6969 final validConfig = Configuration (
7070 domain: 'domain' ,
@@ -77,6 +77,22 @@ void main() {
7777 expect (await completer.future, equals ('dummy-token' ));
7878 });
7979
80+ test ('When SDK was initialized, getTokens() should return tokens' , () async {
81+ final completer = Completer <String >();
82+
83+ Mindbox .instance.getTokens ((deviceToken) => completer.complete (deviceToken));
84+
85+ final validConfig = Configuration (
86+ domain: 'domain' ,
87+ endpointIos: 'endpointIos' ,
88+ endpointAndroid: 'endpointAndroid' ,
89+ subscribeCustomerIfCreated: true );
90+
91+ Mindbox .instance.init (configuration: validConfig);
92+
93+ expect (await completer.future, equals ('dummy-tokens' ));
94+ });
95+
8096 test ('When SDK was not initialized, getToken() should not return token' ,
8197 () async {
8298 final completer = Completer <String >();
0 commit comments