-
-
Notifications
You must be signed in to change notification settings - Fork 34
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Leonardo Colman Lopes <[email protected]>
- Loading branch information
Showing
7 changed files
with
196 additions
and
0 deletions.
There are no files selected for viewing
28 changes: 28 additions & 0 deletions
28
app/src/test/kotlin/br/com/colman/petals/withdrawal/data/AngerTest.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,28 @@ | ||
package br.com.colman.petals.withdrawal.data | ||
|
||
import io.kotest.core.spec.style.FunSpec | ||
import io.kotest.matchers.shouldBe | ||
import java.time.Duration.ofDays | ||
|
||
class AngerTest : FunSpec({ | ||
|
||
val target = AngerDataPoints | ||
|
||
test("Should match the snapshot") { | ||
val snapshot = mapOf( | ||
ofDays(-1) to 0.16, | ||
ofDays(0) to 0.16, | ||
ofDays(2) to 0.35, | ||
ofDays(5) to 0.38, | ||
ofDays(8) to 0.39, | ||
ofDays(11) to 0.40, | ||
ofDays(14) to 0.36, | ||
ofDays(17) to 0.38, | ||
ofDays(20) to 0.20, | ||
ofDays(23) to 0.17, | ||
ofDays(25) to 0.09, | ||
) | ||
|
||
target shouldBe snapshot | ||
} | ||
}) |
28 changes: 28 additions & 0 deletions
28
app/src/test/kotlin/br/com/colman/petals/withdrawal/data/DecreasedAppetiteTest.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,28 @@ | ||
package br.com.colman.petals.withdrawal.data | ||
|
||
import io.kotest.core.spec.style.FunSpec | ||
import io.kotest.matchers.shouldBe | ||
import java.time.Duration.ofDays | ||
|
||
class DecreasedAppetiteTest : FunSpec({ | ||
|
||
val target = DecreasedAppetiteDataPoints | ||
|
||
test("Should match the snapshot") { | ||
val snapshot = mapOf( | ||
ofDays(-1) to 0.32, | ||
ofDays(0) to 0.32, | ||
ofDays(2) to 0.89, | ||
ofDays(5) to 0.65, | ||
ofDays(8) to 0.39, | ||
ofDays(11) to 0.36, | ||
ofDays(14) to 0.29, | ||
ofDays(17) to 0.20, | ||
ofDays(20) to 0.19, | ||
ofDays(23) to 0.22, | ||
ofDays(25) to 0.16, | ||
) | ||
|
||
target shouldBe snapshot | ||
} | ||
}) |
28 changes: 28 additions & 0 deletions
28
app/src/test/kotlin/br/com/colman/petals/withdrawal/data/DiscomfortTest.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,28 @@ | ||
package br.com.colman.petals.withdrawal.data | ||
|
||
import io.kotest.core.spec.style.FunSpec | ||
import io.kotest.matchers.shouldBe | ||
import java.time.Duration.ofDays | ||
|
||
class DiscomfortTest : FunSpec({ | ||
|
||
val target = DiscomfortDataPoints | ||
|
||
test("Should match the snapshot") { | ||
val snapshot = mapOf( | ||
ofDays(-1) to 3.5, | ||
ofDays(0) to 3.5, | ||
ofDays(2) to 7.5, | ||
ofDays(5) to 7.3, | ||
ofDays(8) to 6.6, | ||
ofDays(11) to 5.3, | ||
ofDays(14) to 5.0, | ||
ofDays(17) to 5.0, | ||
ofDays(20) to 4.0, | ||
ofDays(23) to 3.5, | ||
ofDays(25) to 3.0, | ||
) | ||
|
||
target shouldBe snapshot | ||
} | ||
}) |
28 changes: 28 additions & 0 deletions
28
app/src/test/kotlin/br/com/colman/petals/withdrawal/data/IrritabilityTest.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,28 @@ | ||
package br.com.colman.petals.withdrawal.data | ||
|
||
import io.kotest.core.spec.style.FunSpec | ||
import io.kotest.matchers.shouldBe | ||
import java.time.Duration.ofDays | ||
|
||
class IrritabilityTest : FunSpec({ | ||
|
||
val target = IrritabilityDataPoints | ||
|
||
test("Should match the snapshot") { | ||
val snapshot = mapOf( | ||
ofDays(-1) to 0.5, | ||
ofDays(0) to 0.5, | ||
ofDays(2) to 0.9, | ||
ofDays(5) to 1.0, | ||
ofDays(8) to 0.85, | ||
ofDays(11) to 0.75, | ||
ofDays(14) to 0.70, | ||
ofDays(17) to 0.66, | ||
ofDays(20) to 0.52, | ||
ofDays(23) to 0.32, | ||
ofDays(25) to 0.26, | ||
) | ||
|
||
target shouldBe snapshot | ||
} | ||
}) |
28 changes: 28 additions & 0 deletions
28
app/src/test/kotlin/br/com/colman/petals/withdrawal/data/NervousnessAnxietyTest.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,28 @@ | ||
package br.com.colman.petals.withdrawal.data | ||
|
||
import io.kotest.core.spec.style.FunSpec | ||
import io.kotest.matchers.shouldBe | ||
import java.time.Duration.ofDays | ||
|
||
class NervousnessAnxietyTest : FunSpec({ | ||
|
||
val target = NervousnessAnxietyDataPoints | ||
|
||
test("Should match the snapshot") { | ||
val snapshot = mapOf( | ||
ofDays(-1) to 0.43, | ||
ofDays(0) to 0.43, | ||
ofDays(2) to 0.60, | ||
ofDays(5) to 0.61, | ||
ofDays(8) to 0.54, | ||
ofDays(11) to 0.46, | ||
ofDays(14) to 0.39, | ||
ofDays(17) to 0.37, | ||
ofDays(20) to 0.21, | ||
ofDays(23) to 0.25, | ||
ofDays(25) to 0.25, | ||
) | ||
|
||
target shouldBe snapshot | ||
} | ||
}) |
28 changes: 28 additions & 0 deletions
28
app/src/test/kotlin/br/com/colman/petals/withdrawal/data/RestlessnessTest.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,28 @@ | ||
package br.com.colman.petals.withdrawal.data | ||
|
||
import io.kotest.core.spec.style.FunSpec | ||
import io.kotest.matchers.shouldBe | ||
import java.time.Duration.ofDays | ||
|
||
class RestlessnessTest : FunSpec({ | ||
|
||
val target = RestlessnessDataPoints | ||
|
||
test("Should match the snapshot") { | ||
val snapshot = mapOf( | ||
ofDays(-1) to 0.43, | ||
ofDays(0) to 0.43, | ||
ofDays(2) to 0.71, | ||
ofDays(5) to 1.06, | ||
ofDays(8) to 0.81, | ||
ofDays(11) to 0.53, | ||
ofDays(14) to 0.45, | ||
ofDays(17) to 0.33, | ||
ofDays(20) to 0.29, | ||
ofDays(23) to 0.32, | ||
ofDays(25) to 0.17, | ||
) | ||
|
||
target shouldBe snapshot | ||
} | ||
}) |
28 changes: 28 additions & 0 deletions
28
app/src/test/kotlin/br/com/colman/petals/withdrawal/data/SleepDifficultyTest.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,28 @@ | ||
package br.com.colman.petals.withdrawal.data | ||
|
||
import io.kotest.core.spec.style.FunSpec | ||
import io.kotest.matchers.shouldBe | ||
import java.time.Duration.ofDays | ||
|
||
class SleepDifficultyTest : FunSpec({ | ||
|
||
val target = SleepDifficultyDataPoints | ||
|
||
test("Should match the snapshot") { | ||
val snapshot = mapOf( | ||
ofDays(-1) to 0.5, | ||
ofDays(0) to 0.5, | ||
ofDays(2) to 1.0, | ||
ofDays(5) to 0.87, | ||
ofDays(8) to 0.90, | ||
ofDays(11) to 0.53, | ||
ofDays(14) to 0.56, | ||
ofDays(17) to 0.97, | ||
ofDays(20) to 0.85, | ||
ofDays(23) to 0.53, | ||
ofDays(25) to 0.53, | ||
) | ||
|
||
target shouldBe snapshot | ||
} | ||
}) |