-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
10eb369
commit c3be421
Showing
36 changed files
with
143 additions
and
64 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<manifest | ||
xmlns:android="http://schemas.android.com/apk/res/android"> | ||
|
||
<application> | ||
|
||
<receiver | ||
android:name=".domain.test.TestDataBroadcastReceiver" | ||
android:enabled="true" | ||
android:exported="true" /> | ||
|
||
</application> | ||
|
||
</manifest> |
44 changes: 44 additions & 0 deletions
44
app/src/automation/kotlin/com/ivanovsky/passnotes/injection/DebugModuleBuilder.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
package com.ivanovsky.passnotes.injection | ||
|
||
import android.content.Context | ||
import com.ivanovsky.passnotes.data.repository.settings.Settings | ||
import com.ivanovsky.passnotes.domain.LoggerInteractor | ||
import com.ivanovsky.passnotes.injection.modules.BiometricModule | ||
import com.ivanovsky.passnotes.injection.modules.CoreModule | ||
import com.ivanovsky.passnotes.injection.modules.debug.DebugFileSystemProvidersModule | ||
import com.ivanovsky.passnotes.injection.modules.debug.DebugModule | ||
import com.ivanovsky.passnotes.injection.modules.debug.FakeBiometricModule | ||
import com.ivanovsky.passnotes.injection.modules.UiModule | ||
import com.ivanovsky.passnotes.injection.modules.UseCaseModule | ||
import org.koin.core.module.Module | ||
|
||
// Is loaded via reflection in App.kt | ||
class DebugModuleBuilder( | ||
private val context: Context, | ||
private val loggerInteractor: LoggerInteractor, | ||
private val settings: Settings | ||
) : DIModuleBuilder { | ||
|
||
override var isExternalStorageAccessEnabled: Boolean = false | ||
|
||
override fun buildModules(): List<Module> { | ||
val isLoadFakeBiometricModule = settings.testToggles?.isFakeBiometricEnabled ?: false | ||
val isFakeFileSystemEnabled = settings.testToggles?.isFakeFileSystemEnabled ?: false | ||
|
||
return listOf( | ||
CoreModule.build(loggerInteractor), | ||
DebugModule.build(), | ||
DebugFileSystemProvidersModule.build( | ||
isExternalStorageAccessEnabled = isExternalStorageAccessEnabled, | ||
isFakeFileSystemEnabled = isFakeFileSystemEnabled | ||
), | ||
if (isLoadFakeBiometricModule) { | ||
FakeBiometricModule.build() | ||
} else { | ||
BiometricModule.build() | ||
}, | ||
UseCaseModule.build(), | ||
UiModule.build() | ||
) | ||
} | ||
} |
6 changes: 0 additions & 6 deletions
6
...ebug/kotlin/com/ivanovsky/passnotes/data/repository/file/entity/StorageDestinationType.kt
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...repository/file/DatabaseContentFactory.kt → ...itory/file/fake/DatabaseContentFactory.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 4 additions & 2 deletions
6
...epository/file/DebugFileSystemResolver.kt → ...tory/file/fake/DebugFileSystemResolver.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...sitory/file/FakeDatabaseContentFactory.kt → ...y/file/fake/FakeDatabaseContentFactory.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 10 additions & 10 deletions
20
...s/data/repository/file/FakeFileFactory.kt → ...a/repository/file/fake/FakeFileFactory.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...a/repository/file/FakeFileOutputStream.kt → ...ository/file/fake/FakeFileOutputStream.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
12 changes: 7 additions & 5 deletions
12
...s/data/repository/file/FakeFileStorage.kt → ...a/repository/file/fake/FakeFileStorage.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 3 additions & 1 deletion
4
...itory/file/FakeFileSystemAuthenticator.kt → .../file/fake/FakeFileSystemAuthenticator.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...y/passnotes/data/repository/file/Utils.kt → ...snotes/data/repository/file/fake/Utils.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
.../repository/file/delay/ThreadThrottler.kt → ...sitory/file/fake/delay/ThreadThrottler.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 2 additions & 2 deletions
4
...ository/file/delay/ThreadThrottlerImpl.kt → ...ry/file/fake/delay/ThreadThrottlerImpl.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 2 additions & 2 deletions
4
...epository/file/entity/FakeStorageEntry.kt → ...tory/file/fake/entity/FakeStorageEntry.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 6 additions & 0 deletions
6
...kotlin/com/ivanovsky/passnotes/data/repository/file/fake/entity/StorageDestinationType.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
package com.ivanovsky.passnotes.data.repository.file.fake.entity | ||
|
||
enum class StorageDestinationType { | ||
LOCAL, | ||
REMOTE | ||
} |
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion
2
...in/biometric/ClearTextBiometricDecoder.kt → ...st/biometric/ClearTextBiometricDecoder.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...in/biometric/ClearTextBiometricEncoder.kt → ...st/biometric/ClearTextBiometricEncoder.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 2 additions & 1 deletion
3
...ometric/FakeBiometricAuthenticatorImpl.kt → ...ometric/FakeBiometricAuthenticatorImpl.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 2 additions & 1 deletion
3
.../biometric/FakeBiometricInteractorImpl.kt → .../biometric/FakeBiometricInteractorImpl.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
8 changes: 4 additions & 4 deletions
8
...modules/DebugFileSystemProvidersModule.kt → ...s/debug/DebugFileSystemProvidersModule.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...assnotes/injection/modules/DebugModule.kt → ...es/injection/modules/debug/DebugModule.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 3 additions & 3 deletions
6
.../injection/modules/FakeBiometricModule.kt → ...tion/modules/debug/FakeBiometricModule.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters