diff --git a/.github/workflows/build-pr.yml b/.github/workflows/build-pr.yml index c2f6bb1..daf4e10 100644 --- a/.github/workflows/build-pr.yml +++ b/.github/workflows/build-pr.yml @@ -15,9 +15,3 @@ jobs: uses: eskatos/gradle-command-action@v1 with: arguments: build - - name: Test Report - uses: scacap/action-surefire-report@v1 - if: always() - with: - report_paths: "build/test-results/test/TEST-*.xml" - github_token: ${{ secrets.GITHUB_TOKEN }} diff --git a/src/test/kotlin/AppTest.kt b/src/test/kotlin/AppTest.kt index 72598e6..d017e38 100644 --- a/src/test/kotlin/AppTest.kt +++ b/src/test/kotlin/AppTest.kt @@ -5,7 +5,7 @@ import com.google.firebase.FirebasePlatform import com.google.firebase.initialize import org.junit.Test -class AppTest { +class AppTest : FirebaseTest() { @Test fun testInitialize() { FirebasePlatform.initializeFirebasePlatform(object : FirebasePlatform() { diff --git a/src/test/kotlin/FirebaseTest.kt b/src/test/kotlin/FirebaseTest.kt new file mode 100644 index 0000000..224b473 --- /dev/null +++ b/src/test/kotlin/FirebaseTest.kt @@ -0,0 +1,9 @@ +import com.google.firebase.FirebaseApp +import org.junit.Before + +abstract class FirebaseTest { + @Before + fun beforeEach() { + FirebaseApp.clearInstancesForTest() + } +} diff --git a/src/test/kotlin/FirestoreTest.kt b/src/test/kotlin/FirestoreTest.kt index 4f27899..50677f4 100644 --- a/src/test/kotlin/FirestoreTest.kt +++ b/src/test/kotlin/FirestoreTest.kt @@ -11,7 +11,7 @@ import org.junit.Before import org.junit.Test import java.io.File -class FirestoreTest { +class FirestoreTest : FirebaseTest() { @Before fun initialize() { FirebasePlatform.initializeFirebasePlatform(object : FirebasePlatform() {