Skip to content

Commit 13341fc

Browse files
committed
[FEAT] Format all files needed with ktlintFormat
1 parent b6a20c7 commit 13341fc

File tree

81 files changed

+109
-146
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

81 files changed

+109
-146
lines changed

data/src/androidTest/java/com/mikhaellopez/data/persistence/DatabaseFactoryTest.kt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,5 +10,4 @@ object DatabaseFactoryTest {
1010
// allowing main thread queries, just for testing
1111
.allowMainThreadQueries()
1212
.build()
13-
14-
}
13+
}

data/src/androidTest/java/com/mikhaellopez/data/persistence/dao/CardDaoTest.kt

Lines changed: 19 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -137,11 +137,13 @@ open class CardDaoTest {
137137
assert(database.cardDao().insert(entity1) > 0)
138138
assert(database.cardDao().insert(entity2) > 0)
139139

140-
assert(database.cardDao().getAll().let {
141-
it.size == 2
142-
&& it[0].compareTo(entity1)
143-
&& it[1].compareTo(entity2)
144-
})
140+
assert(
141+
database.cardDao().getAll().let {
142+
it.size == 2 &&
143+
it[0].compareTo(entity1) &&
144+
it[1].compareTo(entity2)
145+
}
146+
)
145147
}
146148

147149
@Test
@@ -172,17 +174,16 @@ open class CardDaoTest {
172174

173175
private fun CardEntity?.compareTo(entity: CardEntity): Boolean =
174176
this?.run {
175-
name == entity.name
176-
&& frenchName == entity.frenchName
177-
&& japaneseName == entity.japaneseName
178-
&& type == entity.type
179-
&& rarity == entity.rarity
180-
&& pokemonNumber == entity.pokemonNumber
181-
&& picture == entity.picture
182-
&& illustrator == entity.illustrator
183-
&& wikiLink == entity.wikiLink
184-
&& number == entity.number
185-
&& isCheck == entity.isCheck
177+
name == entity.name &&
178+
frenchName == entity.frenchName &&
179+
japaneseName == entity.japaneseName &&
180+
type == entity.type &&
181+
rarity == entity.rarity &&
182+
pokemonNumber == entity.pokemonNumber &&
183+
picture == entity.picture &&
184+
illustrator == entity.illustrator &&
185+
wikiLink == entity.wikiLink &&
186+
number == entity.number &&
187+
isCheck == entity.isCheck
186188
} ?: false
187-
188-
}
189+
}

data/src/main/java/com/mikhaellopez/data/di/DataSourceModule.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,4 +36,4 @@ val koinDataSourceModules = listOf(
3636
ProcessorModule().module,
3737
MapperModule().module,
3838
repositoryModule
39-
)
39+
)

data/src/main/java/com/mikhaellopez/data/di/MapperModule.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@ import org.koin.core.annotation.Module
55

66
@Module
77
@ComponentScan("com.mikhaellopez.data.mapper")
8-
class MapperModule
8+
class MapperModule

data/src/main/java/com/mikhaellopez/data/di/NetModule.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@ import org.koin.core.annotation.Module
55

66
@Module
77
@ComponentScan("com.mikhaellopez.data.net")
8-
class NetModule
8+
class NetModule

data/src/main/java/com/mikhaellopez/data/di/ProcessorModule.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@ import org.koin.core.annotation.Module
55

66
@Module
77
@ComponentScan("com.mikhaellopez.data.persistence.processor")
8-
class ProcessorModule
8+
class ProcessorModule

data/src/main/java/com/mikhaellopez/data/mapper/CardMapper.kt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -104,5 +104,4 @@ class CardMapper {
104104
fun transformToEntity(modelCollection: Collection<Card>): List<CardEntity> =
105105
modelCollection.map { transformToEntity(it) }
106106
//endregion
107-
108-
}
107+
}

data/src/main/java/com/mikhaellopez/data/net/HttpClientFactory.kt

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,13 @@ open class HttpClientFactory {
2222

2323
open fun createHttpClient(context: Context): HttpClient = HttpClient(OkHttp) {
2424
install(ContentNegotiation) {
25-
json(Json {
26-
prettyPrint = BuildConfig.DEBUG
27-
isLenient = true
28-
ignoreUnknownKeys = true
29-
})
25+
json(
26+
Json {
27+
prettyPrint = BuildConfig.DEBUG
28+
isLenient = true
29+
ignoreUnknownKeys = true
30+
}
31+
)
3032
}
3133

3234
install(DefaultRequest) {
@@ -56,5 +58,4 @@ open class HttpClientFactory {
5658
}
5759
}
5860
}
59-
60-
}
61+
}

data/src/main/java/com/mikhaellopez/data/net/NetworkChecker.kt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,5 +37,4 @@ class NetworkChecker(private val context: Context) {
3737
} ?: false
3838
}
3939
} ?: false
40-
4140
}

data/src/main/java/com/mikhaellopez/data/net/api/PokeApi.kt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,5 +15,4 @@ class PokeApi(private val client: HttpClient) {
1515

1616
suspend fun getCardList(): List<CardDTO> =
1717
client.get("$BASE_URL/poke.json").body()
18-
1918
}

0 commit comments

Comments
 (0)