black-06
a80707de9e
Create and drop view ( #6097 )
...
* create view
* add comment
* fix test
* check param and add comment
2023-02-27 15:43:10 +08:00
Cr
04cbd956eb
test: pgsql migrate unique index ( #6028 )
2023-02-18 09:21:07 +08:00
Michael Anstis
532e9cf4cc
Issue 6054: Unscoped not working with PreLoad on Joins ( #6058 )
...
* Issue 6054: Unscoped not working with PreLoad on Joins
* Formatting
---------
Co-authored-by: Michael Anstis <manstis@redhat.com>
2023-02-18 09:06:43 +08:00
Cheese
02b7e26f6b
feat: add tidb integration test cases ( #6014 )
...
* feat: support tidb integration test
* feat: update the mysql driver version to test
2023-02-08 16:29:09 +08:00
Jinzhu
3d91802b1d
Fix unexpected alter table in auto migration, close #5942 , #5943
2023-01-02 21:06:04 +08:00
Haibo
16a272209a
fix(migrator): Tag default:'null' always causes field migration #5953 ( #5954 )
...
* fix(migrator): Tag default:'null' always causes field migration #5953
* Update migrate_test.go
* Update migrate_test.go
* Update migrate_test.go
Co-authored-by: Jinzhu <wosmvp@gmail.com>
2023-01-01 22:14:28 +08:00
Haibo
da2b2861de
fix(migrator): ignore relationships when migrating #5913 ( #5946 )
2023-01-01 19:54:28 +08:00
Cr
794edad60e
test(MigrateColumn): mock alter column to improve field compare ( #5499 )
...
* test(MigrateColumn): mock alter column to improve field compare
* Update migrate_test.go
* Update migrate_test.go
* Update migrate_test.go
Co-authored-by: Jinzhu <wosmvp@gmail.com>
2022-12-24 17:42:16 +08:00
Ning
bbd2bbe521
fix:Issue migrating field with CURRENT_TIMESTAMP ( #5906 )
...
Co-authored-by: ningfei <accelerator314@outlook.com>
2022-12-24 11:02:11 +08:00
Cr
9d82aa5673
test: invalid cache plan with prepare stmt ( #5778 )
...
* test: invalid cache plan with prepare stmt
* test: more test cases
* test: drop and rename column
2022-10-20 14:10:47 +08:00
viatoriche / Maxim Panfilov
62593cfad0
add test: TestAutoMigrateInt8PG: shouldn't execute ALTER COLUMN TYPE smallint, close #5762
2022-10-18 17:28:06 +08:00
Jinzhu
983e96f142
Add tests for alter column type
2022-10-08 16:04:57 +08:00
Cr
5ed7b1a65e
fix: same embedded filed name ( #5705 )
2022-09-22 11:25:03 +08:00
Cr
46bce170ca
test: pg array type ( #5480 )
2022-07-04 16:42:27 +08:00
Cr
c74bc57add
fix: association many2many duplicate elem ( #5473 )
...
* fix: association many2many duplicate elem
* chore: gofumpt style
2022-07-01 15:12:15 +08:00
Cr
235c093bb9
fix(MigrateColumn):declared different type without length ( #5465 )
2022-06-29 10:07:42 +08:00
Cr
93986de8e4
fix: migrate column default value ( #5359 )
...
Co-authored-by: Jinzhu <wosmvp@gmail.com>
2022-05-28 23:09:13 +08:00
Cr
7d1a92d60e
test: test for skip prepared when auto migrate ( #5350 )
2022-05-22 16:12:28 +08:00
black-06
f5e77aab2f
fix: quote index when creating table ( #5331 )
2022-05-17 10:59:53 +08:00
Cr
373bcf7aca
fix: many2many auto migrate ( #5322 )
...
* fix: many2many auto migrate
* fix: uuid ossp
2022-05-09 10:07:18 +08:00
Heliner
d3488ae6bc
fix: add judge result of auto_migrate ( #5306 )
...
Co-authored-by: fredhan <fredhan@futunn.com>
2022-04-30 09:50:53 +08:00
Cr
bd7e42ec65
fix: AutoMigrate with special table name ( #5301 )
...
* fix: AutoMigrate with special table name
* test: migrate with special table name
2022-04-27 21:13:48 +08:00
Cr
a0cc631272
test: test for postgrs serial column ( #5234 )
...
* test: test for postgrs sercial column
* test: only for postgres
* chore: spelling mistake
* test: for drop sequence
2022-04-24 12:13:27 +08:00
Jin
9a4d10be64
style: fix coding typo ( #5184 )
2022-03-24 09:31:58 +08:00
Jinzhu
48ced75d1d
Improve support for AutoMigrate
2022-02-19 23:42:20 +08:00
Jinzhu
0af95f509a
Enhance migrator Columntype interface ( #5088 )
...
* Update Migrator ColumnType interface
* Update MigrateColumn Test
* Upgrade test drivers
* Fix typo
2022-02-19 17:02:53 +08:00
halfcrazy
f757b8fdc9
fix: auto migration column order unpredictable ( #4980 )
2022-01-06 18:55:20 +08:00
kinggo
b47cf57f5e
ci: add gofumpt check in reviewdog ( #4973 )
2022-01-06 15:02:53 +08:00
Jinzhu
3a3b82263a
Fix auto migration always alert table, close #4198
2021-11-29 20:24:16 +08:00
Jinzhu
92d5a959a0
Fix tests
2021-11-29 15:16:57 +08:00
Jinzhu
e1b4c066a8
Fix FullSaveAssociations, close #4874
2021-11-29 11:02:44 +08:00
dino.ma
5e64ac7de9
feat(migrator,migrator/migrator.go,tests/migrate_test.go) : Get multiple data tables for migrator. ( #4841 )
...
* feat(migrator,migrator/migrator.go,tests/migrate_test.go) : Get multiple data tables for migrator.
* feat(migrator.go and migrator/migrator.go) : remove Table Struct replace with []string
* fix(migrator) : Return all data tables
* Update migrator.go
* fix(migrator/migrator.go):remove var sql
* feat(migrate_test.go/go.mod):update sqlserver,sqlite,postgres,pq version and add getTables test
* fix(migrate_test.go):change GetTables Method Test,use intersection
Co-authored-by: dino.ma <mashengjie03@baidu.com>
2021-11-13 14:03:33 +08:00
Mayank Govilla
d9d5c4dce0
Fix self-referential belongs to constraint ( #4801 )
...
* create tests for self-ref has one migration
* add relation equality check to avoid skipping self-referential schemas
* remove drop table error check
2021-11-08 09:47:29 +08:00
Jason Lee
d3211908a0
Refactor ParseWithSchemaTable method and improve test. ( #4789 )
...
* Refactor ParseWithSchemaTable method and improve test.
* Fix schema.ParseWithSchemaTable method for only use schemaTable in migrator and improve test.
* Rename `schemaTable` to `specialTableName` for clearly argument.
2021-10-25 11:26:44 +08:00
Wendell Sun
a3bd9c3ea2
fix: automigrate error caused by indexes while using dynamic table name
2021-10-19 09:59:57 +08:00
Jinzhu
d4c838c1ce
Upgrade sqlite driver
2021-10-08 17:31:58 +08:00
s-takehana
2202e99cbf
Fix create index with comments in MySQL ( #4521 )
...
* Fix create index with comments in MySQL
* Fix tests
2021-07-18 11:47:44 +08:00
Jinzhu
912360097a
Fix Scopes with Migrator, close #4145
2021-03-11 10:36:14 +08:00
Jinzhu
73d44a4f97
Fix create duplicated constraint, close #4090
2021-02-16 08:52:56 +08:00
yrong1997
2ba612e805
Add field tag to ignore migration ( #4028 )
...
* Add field tag to ignore migration
* Fix null value with space
* refactor migration tag
2021-02-09 16:03:02 +08:00
Jinzhu
916338a9e1
Test migrate constraints, close #3986
2021-01-26 13:39:34 +08:00
Jinzhu
0aef8acc11
Add smart auto migrate tests
2020-10-22 16:36:27 +08:00
Jinzhu
cc6a64adfb
Support smart migrate, close #3078
2020-08-23 18:16:12 +08:00
Jinzhu
90183fadde
Allow advanced table with args
2020-07-19 21:30:24 +08:00
Jinzhu
4201f7bdab
Fix create unique index when creating table, close #3081
2020-06-23 22:14:41 +08:00
Jinzhu
d0764bead1
Test migrate with comment and check created constraints
2020-06-21 13:59:43 +08:00
Jinzhu
d11c424334
Fix typo
2020-06-07 15:26:43 +08:00
Jinzhu
8bb05a5a69
Refactor tests files
2020-06-02 10:50:38 +08:00
Jinzhu
e986371a42
Rename package name
2020-06-02 09:18:01 +08:00
Jinzhu
bc01eb28ad
Fix tests script
2020-06-02 00:24:16 +08:00