My table mappings are defined through decorated attributes and I access the data through Cassandra.Mapping.Mapper. For the XUnit tests I want to use different Cassandra keyspaces for each test class to avoid interference between the tests. But when the test classes connect to the cluster and instantiate the Mapper, the mapper seems to randomly map to one keyspace. Executing raw CQL on the session works in the correct keyspace.
Should the keyspace used by the Mapper not be defined by the sessions' keyspace?
var session = Cluster.Builder().AddContactPoint("127.0.0.1").Build().Connect(keyspacename);
var m = new Mapper(session);