Skip to content

Commit

Permalink
Remove InstantTaskExecutor rule as no longer needed (#923)
Browse files Browse the repository at this point in the history
  • Loading branch information
dturner committed Mar 22, 2023
1 parent 5759ed7 commit a45c3c0
Showing 1 changed file with 0 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@

package com.example.android.architecture.blueprints.todoapp.data.source.local

import androidx.arch.core.executor.testing.InstantTaskExecutorRule
import androidx.room.Room
import androidx.test.core.app.ApplicationProvider.getApplicationContext
import androidx.test.ext.junit.runners.AndroidJUnit4
Expand Down Expand Up @@ -44,14 +43,9 @@ class TaskDaoTest {
).allowMainThreadQueries().build()

// Set the main coroutines dispatcher for unit testing.
@ExperimentalCoroutinesApi
@get:Rule
val mainCoroutineRule = MainCoroutineRule()

// Executes each task synchronously using Architecture Components.
@get:Rule
val instantExecutorRule = InstantTaskExecutorRule()

// Ensure that we use an empty database for each test.
@Before
fun initDb() = database.clearAllTables()
Expand Down

3 comments on commit a45c3c0

@sohaib67
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hi how are you

@sohaib67
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fine

@sohaib67
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[j](https//construction calculator)

Please sign in to comment.