projects
/
dbsrgits/SQL-Translator.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
(parent:
5ca2365
)
Fix TT templates and tests
Peter Rabbitson [Sat, 3 Oct 2009 18:06:40 +0000 (18:06 +0000)]
t/18ttschema-producer.t
patch
|
blob
|
blame
|
history
t/34tt-base.t
patch
|
blob
|
blame
|
history
t/data/template/basic.tt
patch
|
blob
|
blame
|
history
diff --git
a/t/18ttschema-producer.t
b/t/18ttschema-producer.t
index
82ce0fe
..
e28a616
100644
(file)
--- a/
t/18ttschema-producer.t
+++ b/
t/18ttschema-producer.t
@@
-289,6
+289,20
@@
Fields
order: 1
table: Another
+ num
+ data_type: numeric
+ size: 10,2
+ is_nullable: 1
+ default_value:
+ is_primary_key: 0
+ is_unique: 0
+ is_auto_increment: 0
+ is_foreign_key: 0
+ foreign_key_reference:
+ is_valid: 1
+ order: 2
+ table: Another
+
Indices
diff --git
a/t/34tt-base.t
b/t/34tt-base.t
index
6cda785
..
f69f2aa
100644
(file)
--- a/
t/34tt-base.t
+++ b/
t/34tt-base.t
@@
-50,5
+50,5
@@
Fields: id title description email explicitnulldef explicitemptystring emptytagd
Another
------
-Fields: id
+Fields: id num
diff --git
a/t/data/template/basic.tt
b/t/data/template/basic.tt
index
9e7045a
..
f4e4689
100644
(file)
--- a/
t/data/template/basic.tt
+++ b/
t/data/template/basic.tt
@@
-12,7
+12,7
@@
Fields
[%- FOREACH field = table.get_fields %]
[% field %]
data_type: [% field.data_type %]
- size: [% field.size %]
+ size: [% field.size.join(',') %]
is_nullable: [% field.is_nullable %]
default_value: [% field.default_value %]
is_primary_key: [% field.is_primary_key %]