Alexander Makarov
01c4dde202
Added tests for column schema builder comment() method
2016-08-05 02:22:46 +03:00
Carsten Brandt
86f17c8dad
added tests classes for db related tests
2016-06-20 23:07:07 +02:00
Carsten Brandt
8ba032d147
refactored database tests
...
- changed test class naming for easier copying and searching of classes
- made base tests abstract and made MySQL an equal citisen in the test
hierarchie
- added missing db specific test classes
2016-06-20 19:26:43 +02:00
SilverFire - Dmitry Naumenko
77b29bf927
Added tests to ColumnSchemaBuilderTest in order to verify custom column types work OK
2016-05-22 12:03:44 +03:00
SilverFire - Dmitry Naumenko
b08c82c5fe
Driver specific QueryBuilderTest::testCommentColumn() - improved to use replaceQuotes()
2016-04-20 09:40:21 +03:00
SilverFire - Dmitry Naumenko
0fe27b9d3b
Refactored code in PR #9441
2016-04-19 17:48:25 +03:00
SilverFire - Dmitry Naumenko
c9dfc90be0
Merge branch 'methods_for_schema_builder' of https://github.com/vaseninm/yii2 into vaseninm-methods_for_schema_builder
2016-04-19 12:21:33 +03:00
Chris Harris
91018f6c38
Corrected MSSQL driver name. Fixed array addition to not overwrite matching keys.
2016-02-26 12:44:20 -08:00
Chris Harris
732a51b551
All common column definitions and expected outputs now in QueryBuilderTest::columnTypes(). DbmsSpecificQueryBuilderTest::columnTypes() adds DBMS specific column definitions.
2016-02-26 03:53:05 -08:00
Chris Harris
db5399b124
Added $expectedColumnSchemaBuilder back to test data
2016-02-22 05:28:54 -08:00
Chris Harris
3761682edf
Upgraded some tests. Fixed MySQL test fixtures to create all tables with InnoDB.
2016-02-22 04:53:14 -08:00
Chris Harris
81ff4752d9
Added CHECK modifier to PK schema pattern. Modified UNSIGNED tests to not include modifier by default (i.e. only present when testing DBMSes that support it).
2016-02-22 04:06:17 -08:00
Chris Harris
eaeb926768
Adds char datatype to framework
2016-02-20 01:52:23 -08:00
Alexander Makarov
5cecb09c1b
Fixes #9443 : Added unsigned() to ColumnSchemaBuilder
2015-12-26 15:20:21 +03:00
Edgard Lorraine Messias
7c9b7c77a7
Added tests for dropTable, truncateTable and renameTable
2015-11-20 16:16:44 +03:00
Edgard Lorraine Messias
2d8106a39c
Fixed testCreateTable and testAlterTable in CommandTest for MSSQL and OCI
2015-10-21 00:19:48 +03:00
Matvey Vasenin
a8ec3ebe14
add oracle support (need tested)
2015-08-19 17:10:10 +03:00
Nikola Kovacs
316e95b81d
Remove length from SchemaBuilderTrait::text.
...
close #9307
2015-08-05 22:50:46 +02:00
Carsten Brandt
56902298b4
fixed wrong expectation in QueryBuilder test
2015-08-04 12:58:03 +02:00
Carsten Brandt
0d778d0570
adjusted querybuilder tests to match implementation
2015-08-04 12:15:00 +02:00
Carsten Brandt
681db52ba6
refactored SchemaBuilder
...
- rename class to ColumnSchemaBuilder as this is more appropriate
- changed internal organisation to match how the rest of schema related classes work
- the ColumnSchemaBuilder is now created the same way as QueryBuilder is
- removed static call magic and method annotations, now real methods are called as they are
- the whole code works on objects in a db context now instead of setting database connection in global state
- trait is now used by Migration by default but can be used in other contexts as well
Migration usage is now as follows:
```php
$this->createTable('example_table', [
'id' => $this->primaryKey(),
'name' => $this->string(64)->notNull(),
'type' => $this->integer()->notNull()->defaultValue(10),
'description' => $this->text(),
'rule_name' => $this->string(64),
'data' => $this->text(),
'created_at' => $this->datetime()->notNull(),
'updated_at' => $this->datetime(),
]);
```
2015-08-03 23:25:50 +02:00
Carsten Brandt
7150e830d9
do not use reserved php words as function in schemabuilder
...
there is a reason for them to be reserved, we should not add such workarounds to still use them.
close #9283
2015-08-03 11:21:58 +02:00
Matvey Vasenin
b456f699cc
Implemented SchemaBuilder
2015-07-08 15:38:21 +03:00
John Was
94acb2e126
add unit tests to check lastInsertId
2015-05-16 11:47:31 +02:00
John Was
01345874a3
add working QueryBuilder test for Oracle
2015-05-16 11:31:52 +02:00
Klimov Paul
aa9399c6c0
Merge branch 'master' of github.com:yiisoft/yii2 into 5042-insert-returning
2015-04-20 11:23:38 +03:00
Alexander Makarov
6949992246
Simplified tests directory structure a bit
2015-04-16 12:10:01 +03:00