im trying to test PersistentActor with scalatest but I dont know how to point test code to use something like application-test.conf instead application.conf ( I want to change leveldb store for events to in memory store ). Is there any convenient way to do this?
You could define another application.conf
in your test resources:
src/test/resources/application.conf
This way, you can have test related configuration that will be used by default in your tests.
If you still require multiple configuration settings among your tests, you can always have more than one configuration file in the test resources and explicitly use the one you need:
class PersistentActorSpec extends TestKit(ActorSystem("test-system", ConfigFactory.load("application-test")))
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With