Skip to content

Commit

Permalink
Unit test empty ConfigReader Simple
Browse files Browse the repository at this point in the history
  • Loading branch information
grzegorz-bielski committed Mar 16, 2024
1 parent 1d0dd7a commit cf40f03
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,12 @@ class ReplicationStrategyConfigSpec extends AnyFunSuite with Matchers {
ConfigSource.fromConfig(config.getConfig("simple")).load[ReplicationStrategyConfig] shouldEqual expected.asRight
}

test("apply from empty simple config") {
val config = ConfigFactory.empty()
val expected = Simple()
ConfigSource.fromConfig(config).load[Simple] shouldEqual expected.asRight
}

test("apply from network topology config") {
val config = ConfigFactory.parseURL(getClass.getResource("replication-strategy.conf"))
val expected = NetworkTopology(Nel(DcFactor("dc1", 2), DcFactor("dc2", 3)))
Expand Down

0 comments on commit cf40f03

Please sign in to comment.