Skip to content

Commit 4bf210c

Browse files
committed
[NetLens][Stop Network Interception Use Case ] - clear callback
1 parent ef522e7 commit 4bf210c

1 file changed

Lines changed: 14 additions & 0 deletions

File tree

Tests/NetLensTests/UseCasesTests/StopNetworkInterceptionUseCaseTests.swift

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,22 @@ struct StopNetworkInterceptionUseCaseTests {
3434
#expect(mockInterceptor.isEnabled == false)
3535

3636
#expect(mockInterceptor.disableCallCount == 1)
37+
38+
}
39+
40+
@Test("Clear CallBack")
41+
func executeClearCallBack() {
42+
43+
mockInterceptor.enable()
3744

45+
mockInterceptor.onNetworkCallIntercepted = { _ in }
3846

47+
#expect(mockInterceptor.onNetworkCallIntercepted != nil )
48+
49+
stopNetworkInterceptionUseCase.execute()
50+
51+
#expect(mockInterceptor.onNetworkCallIntercepted == nil)
52+
3953
}
4054
}
4155

0 commit comments

Comments
 (0)