mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-02-24 03:35:58 +00:00
Add notification profile and chat folder backupv2 proto support.
This commit is contained in:
committed by
Greyson Parrelli
parent
c91123e8e8
commit
d1bfa6ee9e
@@ -24,29 +24,29 @@ import java.time.DayOfWeek
|
||||
|
||||
@RunWith(RobolectricTestRunner::class)
|
||||
@Config(manifest = Config.NONE, application = Application::class)
|
||||
class NotificationProfileDatabaseTest {
|
||||
class NotificationProfileTablesTest {
|
||||
|
||||
@get:Rule
|
||||
val appDependencies = MockAppDependenciesRule()
|
||||
|
||||
private lateinit var db: SQLiteDatabase
|
||||
private lateinit var database: NotificationProfileDatabase
|
||||
private lateinit var database: NotificationProfileTables
|
||||
|
||||
@Before
|
||||
fun setup() {
|
||||
val sqlCipher = TestDatabaseUtil.inMemoryDatabase {
|
||||
NotificationProfileDatabase.CREATE_TABLE.forEach {
|
||||
NotificationProfileTables.CREATE_TABLE.forEach {
|
||||
println(it)
|
||||
this.execSQL(it)
|
||||
}
|
||||
NotificationProfileDatabase.CREATE_INDEXES.forEach {
|
||||
NotificationProfileTables.CREATE_INDEXES.forEach {
|
||||
println(it)
|
||||
this.execSQL(it)
|
||||
}
|
||||
}
|
||||
|
||||
db = sqlCipher.writableDatabase
|
||||
database = NotificationProfileDatabase(ApplicationProvider.getApplicationContext(), sqlCipher)
|
||||
database = NotificationProfileTables(ApplicationProvider.getApplicationContext(), sqlCipher)
|
||||
}
|
||||
|
||||
@After
|
||||
@@ -168,5 +168,5 @@ class NotificationProfileDatabaseTest {
|
||||
}
|
||||
}
|
||||
|
||||
private val NotificationProfileDatabase.NotificationProfileChangeResult.profile: NotificationProfile
|
||||
get() = (this as NotificationProfileDatabase.NotificationProfileChangeResult.Success).notificationProfile
|
||||
private val NotificationProfileTables.NotificationProfileChangeResult.profile: NotificationProfile
|
||||
get() = (this as NotificationProfileTables.NotificationProfileChangeResult.Success).notificationProfile
|
||||
Reference in New Issue
Block a user