src/Cassandra.IntegrationTests/Linq/LinqTable/CreateTable.cs
/// <summary>
/// Attempt to create a table in a non-existent keyspace, specifying the keyspace name in Table constructor's override option
/// Validate error message.
/// </summary>
Attempt to create a table in a non-existent keyspace, specifying the keyspace name in Table constructor's override option
Validate error message.
Attempt to create a table in a non - existent keyspace specifying the keyspace name in Table constructor ' s override option Validate error message .
[Test, TestCassandraVersion(2, 0)]
        public void TableCreate_Create_KeyspaceOverride_NoSuchKeyspace()
        {
            var uniqueTableName = TestUtils.GetUniqueTableName();
            var uniqueKsName = TestUtils.GetUniqueKeyspaceName();
            var table = new Table<AllDataTypesEntity>(_session, new MappingConfiguration(), uniqueTableName, uniqueKsName);
            Assert.Throws<InvalidConfigurationInQueryException>(() => table.Create());
        }
[ Test , TestCassandraVersion ( 2 , 0 ) ] public void TableCreate_Create_KeyspaceOverride_NoSuchKeyspace ( ) { var uniqueTableName = TestUtils . GetUniqueTableName ( ) ; var uniqueKsName = TestUtils . GetUniqueKeyspaceName ( ) ; var table = new Table < AllDataTypesEntity > ( _session , new MappingConfiguration ( ) , uniqueTableName , uniqueKsName ) ; Assert . Throws < InvalidConfigurationInQueryException > ( ( ) => table . Create ( ) ) ; }
Attempt to create a table in a non-existent keyspace, specifying the keyspace name in Table constructor's override option
Validate error message.
Attempt to create a table in a non - existent keyspace specifying the keyspace name in Table constructor ' s override option Validate error message .