File tree Expand file tree Collapse file tree 2 files changed +36
-2
lines changed Expand file tree Collapse file tree 2 files changed +36
-2
lines changed Original file line number Diff line number Diff line change @@ -45,6 +45,24 @@ steps:
4545 - push
4646 - pull_request
4747
48+ - name : test-mysql8
49+ image : golang:1.12
50+ environment :
51+ GO111MODULE : " on"
52+ GOPROXY : " https://goproxy.cn"
53+ TEST_MYSQL_HOST : mysql8
54+ TEST_MYSQL_CHARSET : utf8mb4
55+ TEST_MYSQL_DBNAME : xorm_test
56+ TEST_MYSQL_USERNAME : root
57+ TEST_MYSQL_PASSWORD :
58+ commands :
59+ - make test-mysql
60+ - TEST_CACHE_ENABLE=true make test-mysql
61+ when :
62+ event :
63+ - push
64+ - pull_request
65+
4866- name : test-mysql-utf8mb4
4967 image : golang:1.12
5068 depends_on :
@@ -170,6 +188,7 @@ steps:
170188 - test-vet
171189 - test-sqlite
172190 - test-mysql
191+ - test-mysql8
173192 - test-mymysql
174193 - test-postgres
175194 - test-postgres-schema
@@ -196,6 +215,18 @@ services:
196215 - tag
197216 - pull_request
198217
218+ - name : mysql8
219+ pull : default
220+ image : mysql:8.0
221+ environment :
222+ MYSQL_ALLOW_EMPTY_PASSWORD : yes
223+ MYSQL_DATABASE : xorm_test
224+ when :
225+ event :
226+ - push
227+ - tag
228+ - pull_request
229+
199230- name : pgsql
200231 pull : default
201232 image : postgres:9.5
Original file line number Diff line number Diff line change @@ -6,6 +6,7 @@ package xorm
66
77import (
88 "errors"
9+ "sort"
910 "testing"
1011 "time"
1112
@@ -1141,8 +1142,10 @@ func TestCompositePK(t *testing.T) {
11411142
11421143 pkCols := table .PKColumns ()
11431144 assert .EqualValues (t , 2 , len (pkCols ))
1144- assert .EqualValues (t , "uid" , pkCols [0 ].Name )
1145- assert .EqualValues (t , "tid" , pkCols [1 ].Name )
1145+
1146+ names := []string {pkCols [0 ].Name , pkCols [1 ].Name }
1147+ sort .Strings (names )
1148+ assert .EqualValues (t , []string {"tid" , "uid" }, names )
11461149}
11471150
11481151func TestNoPKIdQueryUpdate (t * testing.T ) {
You can’t perform that action at this time.
0 commit comments