@@ -24,7 +24,7 @@ class IdentityTests: XCTestCase {
2424
2525 func testUpdateWithSameValues( ) throws {
2626 let storage = try makeStorage ( )
27- let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage) )
27+ let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage, offline : NetworkConnectivityCheckerPlugin . Disabled ) )
2828 let sendExpectation = XCTestExpectation ( description: " It should not send identify " )
2929 sendExpectation. isInverted = true
3030 amplitude. add ( plugin: IdentifyInterceptPlugin ( block: { _ in
@@ -53,7 +53,7 @@ class IdentityTests: XCTestCase {
5353
5454 func testUpdateWithIdentity( ) throws {
5555 let storage = try makeStorage ( )
56- let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage) )
56+ let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage, offline : NetworkConnectivityCheckerPlugin . Disabled ) )
5757 let sendExpectation = XCTestExpectation ( description: " It should send identify " )
5858 sendExpectation. assertForOverFulfill = true
5959 amplitude. add ( plugin: IdentifyInterceptPlugin ( block: { _ in
@@ -74,7 +74,7 @@ class IdentityTests: XCTestCase {
7474
7575 func testUpdateWithUserId( ) throws {
7676 let storage = try makeStorage ( )
77- let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage) )
77+ let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage, offline : NetworkConnectivityCheckerPlugin . Disabled ) )
7878 let sendExpectation = XCTestExpectation ( description: " It should not send identify " )
7979 sendExpectation. isInverted = true
8080 amplitude. add ( plugin: IdentifyInterceptPlugin ( block: { _ in
@@ -93,7 +93,7 @@ class IdentityTests: XCTestCase {
9393
9494 func testUpdateWithDeviceId( ) throws {
9595 let storage = try makeStorage ( )
96- let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage) )
96+ let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage, offline : NetworkConnectivityCheckerPlugin . Disabled ) )
9797 let sendExpectation = XCTestExpectation ( description: " It should not send identify " )
9898 sendExpectation. isInverted = true
9999 amplitude. add ( plugin: IdentifyInterceptPlugin ( block: { _ in
@@ -112,7 +112,7 @@ class IdentityTests: XCTestCase {
112112
113113 func testUpdateWithUserProperties( ) throws {
114114 let storage = try makeStorage ( )
115- let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage) )
115+ let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage, offline : NetworkConnectivityCheckerPlugin . Disabled ) )
116116 let sendExpectation = XCTestExpectation ( description: " It should send identify " )
117117 sendExpectation. assertForOverFulfill = true
118118 amplitude. add ( plugin: IdentifyInterceptPlugin ( block: { event in
@@ -134,7 +134,7 @@ class IdentityTests: XCTestCase {
134134
135135 func testSetUserId( ) throws {
136136 let storage = try makeStorage ( )
137- let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage) )
137+ let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage, offline : NetworkConnectivityCheckerPlugin . Disabled ) )
138138 let sendExpectation = XCTestExpectation ( description: " It should not send identify " )
139139 sendExpectation. isInverted = true
140140 amplitude. add ( plugin: IdentifyInterceptPlugin ( block: { _ in
@@ -153,7 +153,7 @@ class IdentityTests: XCTestCase {
153153
154154 func testSetDeviceId( ) throws {
155155 let storage = try makeStorage ( )
156- let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage) )
156+ let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage, offline : NetworkConnectivityCheckerPlugin . Disabled ) )
157157 let sendExpectation = XCTestExpectation ( description: " It should not send identify " )
158158 sendExpectation. isInverted = true
159159 amplitude. add ( plugin: IdentifyInterceptPlugin ( block: { _ in
@@ -174,7 +174,7 @@ class IdentityTests: XCTestCase {
174174
175175 func testIdentifySet( ) throws {
176176 let storage = try makeStorage ( )
177- let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage) )
177+ let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage, offline : NetworkConnectivityCheckerPlugin . Disabled ) )
178178 amplitude. add ( plugin: IdentifyInterceptPlugin ( block: { _ in } ) )
179179
180180 let identify = Identify ( )
@@ -189,7 +189,7 @@ class IdentityTests: XCTestCase {
189189
190190 func testIdentifyUnset( ) throws {
191191 let storage = try makeStorage ( )
192- let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage) )
192+ let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage, offline : NetworkConnectivityCheckerPlugin . Disabled ) )
193193 amplitude. add ( plugin: IdentifyInterceptPlugin ( block: { _ in } ) )
194194 amplitude. identity. userProperties = updatedIdentity. userProperties
195195
@@ -207,7 +207,7 @@ class IdentityTests: XCTestCase {
207207
208208 func testIdentifyClearAll( ) throws {
209209 let storage = try makeStorage ( )
210- let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage) )
210+ let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage, offline : NetworkConnectivityCheckerPlugin . Disabled ) )
211211 amplitude. add ( plugin: IdentifyInterceptPlugin ( block: { _ in } ) )
212212
213213 let identify = Identify ( )
@@ -219,7 +219,7 @@ class IdentityTests: XCTestCase {
219219
220220 func testIdentifyUpdate( ) throws {
221221 let storage = try makeStorage ( )
222- let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage) )
222+ let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage, offline : NetworkConnectivityCheckerPlugin . Disabled ) )
223223 let ignorePlugin = IdentifyInterceptPlugin { _ in }
224224 amplitude. add ( plugin: ignorePlugin)
225225 amplitude. identity. userProperties = updatedIdentity. userProperties
@@ -247,7 +247,7 @@ class IdentityTests: XCTestCase {
247247
248248 func testIdentifyNoOps( ) throws {
249249 let storage = try makeStorage ( )
250- let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage) )
250+ let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage, offline : NetworkConnectivityCheckerPlugin . Disabled ) )
251251 amplitude. add ( plugin: IdentifyInterceptPlugin ( block: { _ in } ) )
252252
253253 let identify = Identify ( )
@@ -265,7 +265,7 @@ class IdentityTests: XCTestCase {
265265
266266 func testIdentifyOrder( ) throws {
267267 let storage = try makeStorage ( )
268- let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage) )
268+ let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage, offline : NetworkConnectivityCheckerPlugin . Disabled ) )
269269 amplitude. add ( plugin: IdentifyInterceptPlugin ( block: { _ in } ) )
270270
271271 let existingProperties = [ " foo " : 1 , " bar " : 2 ]
@@ -285,7 +285,7 @@ class IdentityTests: XCTestCase {
285285
286286 func testIdentifyNonOpProperties( ) throws {
287287 let storage = try makeStorage ( )
288- let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage) )
288+ let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage, offline : NetworkConnectivityCheckerPlugin . Disabled ) )
289289 amplitude. add ( plugin: IdentifyInterceptPlugin ( block: { _ in } ) )
290290
291291 let identify = IdentifyEvent ( )
@@ -300,7 +300,7 @@ class IdentityTests: XCTestCase {
300300
301301 func testIdentifyEventOptionsSetsUserAndDeviceId( ) throws {
302302 let storage = try makeStorage ( )
303- let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage) )
303+ let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage, offline : NetworkConnectivityCheckerPlugin . Disabled ) )
304304 amplitude. add ( plugin: IdentifyInterceptPlugin ( block: { _ in } ) )
305305
306306 amplitude. identify ( userProperties: [ : ] , options: EventOptions ( userId: updatedIdentity. userId,
@@ -317,7 +317,7 @@ class IdentityTests: XCTestCase {
317317
318318 func testReset( ) throws {
319319 let storage = try makeStorage ( )
320- let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage) )
320+ let amplitude = Amplitude ( configuration: Configuration ( apiKey: " " , storageProvider: storage, offline : NetworkConnectivityCheckerPlugin . Disabled ) )
321321 amplitude. reset ( )
322322
323323 XCTAssertEqual ( amplitude. identity. userProperties as NSDictionary , NSDictionary ( ) )
0 commit comments