db deploy - next tests

This commit is contained in:
Jan Prochazka
2021-10-02 16:49:10 +02:00
parent d953d1b342
commit b5f22516b6
3 changed files with 57 additions and 17 deletions

View File

@@ -65,7 +65,7 @@ function columnInfoFromYaml(column: ColumnInfoYaml, table: TableInfoYaml): Colum
columnName: column.name,
dataType: column.type,
autoIncrement: column.autoIncrement,
notNull: column.notNull,
notNull: column.notNull || (table.primaryKey && table.primaryKey.includes(column.name)),
};
return res;
}
@@ -170,5 +170,8 @@ export function databaseInfoFromYamlModel(files: DatabaseModelFile[]): DatabaseI
}
}
}
model.tables = tablesYaml.map(table => tableInfoFromYaml(table, tablesYaml));
return model;
}