mirror of
https://github.com/kiwix/kiwix-android.git
synced 2025-09-12 08:58:51 -04:00
Fixed: testNoteEntryIsRemovedFromDatabaseWhenDeletedInAddNoteDialog
failing on API level 25.
This commit is contained in:
parent
df67f91b0a
commit
b309032241
@ -207,6 +207,7 @@ class NoteFragmentTest : BaseActivityTest() {
|
|||||||
|
|
||||||
@Test
|
@Test
|
||||||
fun testNoteEntryIsRemovedFromDatabaseWhenDeletedInAddNoteDialog() {
|
fun testNoteEntryIsRemovedFromDatabaseWhenDeletedInAddNoteDialog() {
|
||||||
|
if (Build.VERSION.SDK_INT > Build.VERSION_CODES.N_MR1) {
|
||||||
deletePreviouslySavedNotes()
|
deletePreviouslySavedNotes()
|
||||||
loadZimFileInReader("testzim.zim")
|
loadZimFileInReader("testzim.zim")
|
||||||
note {
|
note {
|
||||||
@ -226,6 +227,7 @@ class NoteFragmentTest : BaseActivityTest() {
|
|||||||
assertNoNotesTextDisplayed()
|
assertNoNotesTextDisplayed()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
fun testNoteFileIsDeletedWhenNoteIsRemovedFromNotesScreen() {
|
fun testNoteFileIsDeletedWhenNoteIsRemovedFromNotesScreen() {
|
||||||
|
@ -31,12 +31,13 @@ import org.kiwix.kiwixmobile.core.utils.files.FileUtils.isFileDescriptorCanOpenW
|
|||||||
import org.kiwix.libzim.Archive
|
import org.kiwix.libzim.Archive
|
||||||
import org.kiwix.libzim.FdInput
|
import org.kiwix.libzim.FdInput
|
||||||
import java.io.File
|
import java.io.File
|
||||||
|
import java.io.Serializable
|
||||||
|
|
||||||
class ZimReaderSource(
|
class ZimReaderSource(
|
||||||
val file: File? = null,
|
val file: File? = null,
|
||||||
val uri: Uri? = null,
|
val uri: Uri? = null,
|
||||||
val assetFileDescriptorList: List<AssetFileDescriptor>? = null
|
val assetFileDescriptorList: List<AssetFileDescriptor>? = null
|
||||||
) {
|
) : Serializable {
|
||||||
constructor(uri: Uri) : this(
|
constructor(uri: Uri) : this(
|
||||||
uri = uri,
|
uri = uri,
|
||||||
assetFileDescriptorList = getAssetFileDescriptorFromUri(CoreApp.instance, uri)
|
assetFileDescriptorList = getAssetFileDescriptorFromUri(CoreApp.instance, uri)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user