33
44import  'package:flutter_test/flutter_test.dart' ;
55import  'package:mockito/mockito.dart' ;
6- import  'package:sentry/src/transport/noop_transport.dart' ;
76import  'package:sentry_flutter/src/integrations/web_sdk_integration.dart' ;
8- import  'package:sentry_flutter/src/web/javascript_transport.dart' ;
97import  'package:sentry_flutter/src/web/script_loader/sentry_script_loader.dart' ;
108
119import  '../mocks.dart' ;
@@ -27,7 +25,6 @@ void main() {
2725
2826    group ('enabled' , () {
2927      setUp (() {
30-         fixture.options.enableSentryJs =  true ;
3128        fixture.options.autoInitializeNativeSdk =  true ;
3229      });
3330
@@ -52,17 +49,9 @@ void main() {
5249        _TestScenario (
5350          'with autoInitializeNativeSdk=false' ,
5451          () {
55-             fixture.options.enableSentryJs =  true ;
5652            fixture.options.autoInitializeNativeSdk =  false ;
5753          },
5854        ),
59-         _TestScenario (
60-           'with enableSentryJs=false' ,
61-           () {
62-             fixture.options.enableSentryJs =  false ;
63-             fixture.options.autoInitializeNativeSdk =  true ;
64-           },
65-         ),
6655      ];
6756
6857      for  (final  scenario in  disabledScenarios) {
@@ -84,46 +73,6 @@ void main() {
8473      }
8574    });
8675
87-     group ('transport configuration' , () {
88-       test ('integration disabled: does not use javascript transport' , () async  {
89-         fixture.options.enableSentryJs =  false ;
90-         fixture.options.autoInitializeNativeSdk =  false ;
91- 
92-         expect (fixture.options.transport, isA <NoOpTransport >());
93- 
94-         await  sut.call (fixture.hub, fixture.options);
95- 
96-         expect (fixture.options.transport, isA <NoOpTransport >());
97-       });
98- 
99-       test (
100-           'integration enabled and supportsCaptureEnvelope is false: does not use javascript transport' ,
101-           () async  {
102-         fixture.options.enableSentryJs =  true ;
103-         fixture.options.autoInitializeNativeSdk =  true ;
104-         when (fixture.web.supportsCaptureEnvelope).thenReturn (false );
105- 
106-         expect (fixture.options.transport, isA <NoOpTransport >());
107- 
108-         await  sut.call (fixture.hub, fixture.options);
109- 
110-         expect (fixture.options.transport, isA <NoOpTransport >());
111-       });
112- 
113-       test (
114-           'integration enabled and supportsCaptureEnvelope is true: uses javascript transport' ,
115-           () async  {
116-         fixture.options.enableSentryJs =  true ;
117-         fixture.options.autoInitializeNativeSdk =  true ;
118- 
119-         expect (fixture.options.transport, isA <NoOpTransport >());
120- 
121-         await  sut.call (fixture.hub, fixture.options);
122- 
123-         expect (fixture.options.transport, isA <JavascriptTransport >());
124-       });
125-     });
126- 
12776    test ('closes resources' , () async  {
12877      await  sut.close ();
12978
0 commit comments