Fix android test
|
@ -21,7 +21,7 @@ class AreaScreenshot {
|
|||
private lateinit var context: Context
|
||||
|
||||
private fun saveImage(area: Area, fileName: String, ambientMode: Boolean): File {
|
||||
val paintSettings = AreaAdapter.createAreaPaintSettings(context, 128.0f)
|
||||
val paintSettings = AreaAdapter.createAreaPaintSettings(context, 128.0f, 3)
|
||||
val size = paintSettings.rectF.width().toInt()
|
||||
val testPadding = 4
|
||||
val bitmap = Bitmap.createBitmap(size + testPadding, size + testPadding, Bitmap.Config.ARGB_8888)
|
||||
|
|
Before Width: | Height: | Size: 695 B After Width: | Height: | Size: 957 B |
Before Width: | Height: | Size: 807 B After Width: | Height: | Size: 1.2 KiB |
Before Width: | Height: | Size: 925 B After Width: | Height: | Size: 1.4 KiB |
Before Width: | Height: | Size: 1 KiB After Width: | Height: | Size: 1.6 KiB |
Before Width: | Height: | Size: 689 B After Width: | Height: | Size: 930 B |
Before Width: | Height: | Size: 807 B After Width: | Height: | Size: 1.2 KiB |
Before Width: | Height: | Size: 695 B After Width: | Height: | Size: 957 B |
Before Width: | Height: | Size: 807 B After Width: | Height: | Size: 1.2 KiB |
Before Width: | Height: | Size: 1.6 KiB After Width: | Height: | Size: 1.8 KiB |
Before Width: | Height: | Size: 1.7 KiB After Width: | Height: | Size: 2.1 KiB |
Before Width: | Height: | Size: 936 B After Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 1.7 KiB After Width: | Height: | Size: 1.9 KiB |
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 1.2 KiB |
Before Width: | Height: | Size: 1.9 KiB After Width: | Height: | Size: 2.1 KiB |
Before Width: | Height: | Size: 1.6 KiB After Width: | Height: | Size: 1.3 KiB |
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.5 KiB |
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 1.2 KiB |
Before Width: | Height: | Size: 1.8 KiB After Width: | Height: | Size: 2 KiB |
Before Width: | Height: | Size: 1.6 KiB After Width: | Height: | Size: 1.3 KiB |
Before Width: | Height: | Size: 1.9 KiB After Width: | Height: | Size: 2.1 KiB |
Before Width: | Height: | Size: 1.9 KiB After Width: | Height: | Size: 1.3 KiB |
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 1.6 KiB |
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.2 KiB |
Before Width: | Height: | Size: 2.2 KiB After Width: | Height: | Size: 2.4 KiB |
Before Width: | Height: | Size: 743 B After Width: | Height: | Size: 1.4 KiB |
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.9 KiB |
Before Width: | Height: | Size: 1.2 KiB After Width: | Height: | Size: 1.5 KiB |
Before Width: | Height: | Size: 2.1 KiB After Width: | Height: | Size: 2.7 KiB |
Before Width: | Height: | Size: 1.7 KiB After Width: | Height: | Size: 1.6 KiB |
Before Width: | Height: | Size: 2.3 KiB After Width: | Height: | Size: 2.9 KiB |
Before Width: | Height: | Size: 1.8 KiB After Width: | Height: | Size: 1.7 KiB |
Before Width: | Height: | Size: 1.7 KiB After Width: | Height: | Size: 2.3 KiB |
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 1.5 KiB |
Before Width: | Height: | Size: 2.1 KiB After Width: | Height: | Size: 2.7 KiB |
Before Width: | Height: | Size: 1.8 KiB After Width: | Height: | Size: 1.6 KiB |
Before Width: | Height: | Size: 2.2 KiB After Width: | Height: | Size: 2.8 KiB |
Before Width: | Height: | Size: 2.1 KiB After Width: | Height: | Size: 1.7 KiB |
Before Width: | Height: | Size: 1.8 KiB After Width: | Height: | Size: 2.4 KiB |
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 1.6 KiB |
Before Width: | Height: | Size: 2.5 KiB After Width: | Height: | Size: 3.1 KiB |
Before Width: | Height: | Size: 925 B After Width: | Height: | Size: 1.7 KiB |
Before Width: | Height: | Size: 654 B After Width: | Height: | Size: 879 B |
Before Width: | Height: | Size: 743 B After Width: | Height: | Size: 1 KiB |
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.7 KiB |
Before Width: | Height: | Size: 925 B After Width: | Height: | Size: 1.4 KiB |
Before Width: | Height: | Size: 3 KiB After Width: | Height: | Size: 3.2 KiB |
Before Width: | Height: | Size: 2.6 KiB After Width: | Height: | Size: 2.8 KiB |
Before Width: | Height: | Size: 3.1 KiB After Width: | Height: | Size: 3.3 KiB |
Before Width: | Height: | Size: 2.6 KiB After Width: | Height: | Size: 2.8 KiB |
|
@ -14,11 +14,7 @@ class MinefieldConverter {
|
|||
|
||||
@TypeConverter
|
||||
fun toMinefield(jsonInput: String): Minefield =
|
||||
jsonAdapter.fromJson(jsonInput) ?: Minefield(
|
||||
9,
|
||||
9,
|
||||
9
|
||||
)
|
||||
jsonAdapter.fromJson(jsonInput) ?: Minefield(9, 9, 9,)
|
||||
|
||||
@TypeConverter
|
||||
fun toJsonString(field: Minefield): String = jsonAdapter.toJson(field)
|
||||
|
|
|
@ -24,11 +24,11 @@ val LevelModule = module {
|
|||
}
|
||||
|
||||
single {
|
||||
get<AppDataBase>(AppDataBase::class).saveDao()
|
||||
get(AppDataBase::class).saveDao()
|
||||
}
|
||||
|
||||
single {
|
||||
get<AppDataBase>(AppDataBase::class).statsDao()
|
||||
get(AppDataBase::class).statsDao()
|
||||
}
|
||||
|
||||
single {
|
||||
|
|