Skip to content

Commit

Permalink
fix fakeworkertest
Browse files Browse the repository at this point in the history
  • Loading branch information
simonroesch committed Feb 9, 2022
1 parent 0832f30 commit 085b6c0
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
import org.junit.Test;
import org.junit.runner.RunWith;

import ch.admin.bag.dp3t.networking.CertificatePinning;
import ch.admin.bag.dp3t.networking.FakeWorker;
import ch.admin.bag.dp3t.storage.SecureStorage;
import okhttp3.mockwebserver.Dispatcher;
Expand All @@ -52,6 +53,8 @@ public void setup() throws IOException {
context = InstrumentationRegistry.getInstrumentation().getTargetContext();
Logger.init(context, LogLevel.DEBUG);

CertificatePinning.setEnabled(false, context);

//cancel all work that was scheduled on normal WorkManager on Application creation
WorkManager.getInstance(context).cancelAllWork();

Expand Down

0 comments on commit 085b6c0

Please sign in to comment.