Azavea.NijPredictivePolicing.Test.Common.DB.TableCreationTests.TestSqliteGeneration C# (CSharp) Method

TestSqliteGeneration() private method

private TestSqliteGeneration ( ) : void
return void
        public void TestSqliteGeneration()
        {
            var columns = new List<FixedWidthField>(new FixedWidthField[] {
                new FixedWidthField("FILEID", "File Identification", 6, 1),
                new FixedWidthField("WideText", "State Postal Abbreviation", 200, 7),
                new FixedWidthField("Numeric", "State Postal Abbreviation", 200, 7, FixedWidthTypes.INT),
            });

            string sql = SqliteDataClient.GenerateTableSQLFromFields("test", columns);
            string expectedSql = "CREATE TABLE \"test\" ( ixid INTEGER NOT NULL PRIMARY KEY, FILEID TEXT(6), WideText TEXT(200), Numeric INTEGER(200) ); ";
            _log.Debug("Test generated " + sql);

            Assert.AreEqual(expectedSql, sql);
        }