Skip to content

Console Output

Skipping 121 KB.. Full Log
    ✔ should drop ENUM column and revert drop
    ✔ should create table with ENUM column and revert creation
    ✔ should drop table with ENUM column and revert drop
    ✔ should change non-enum column in to ENUM and revert change
    ✔ should change ENUM column in to non-enum and revert change
    ✔ should change ENUM array column in to non-array and revert change
    ✔ should change ENUM value and revert change
    ✔ should change `enumName` and revert change
    ✔ should not create new type if same `enumName` is used more than once
    ✔ should change both ENUM value and ENUM name and revert change
    ✔ should rename ENUM when column renamed and revert rename
    ✔ should rename ENUM when table renamed and revert rename

  database schema > column types > mssql
    ✔ all types should work correctly - persist and hydrate
    ✔ all types should work correctly - persist and hydrate when options are specified on columns
    ✔ all types should work correctly - persist and hydrate when types are not specified on columns

  database schema > column types > mysql
    ✔ all types should work correctly - persist and hydrate
npm WARN deprecated uuid@3.4.0: Please upgrade  to version 7 or higher.  Older versions may use Math.random() in certain circumstances, which is known to be problematic.  See https://v8.dev/blog/math-random for details.
npm WARN deprecated uuid@3.4.0: Please upgrade  to version 7 or higher.  Older versions may use Math.random() in certain circumstances, which is known to be problematic.  See https://v8.dev/blog/math-random for details.
npm WARN deprecated uuid@3.4.0: Please upgrade  to version 7 or higher.  Older versions may use Math.random() in certain circumstances, which is known to be problematic.  See https://v8.dev/blog/math-random for details.
    ✔ all types should work correctly - persist and hydrate when options are specified on columns
    ✔ all types should work correctly - persist and hydrate when types are not specified on columns

  database schema > column types > oracle
    ✔ all types should work correctly - persist and hydrate
    ✔ all types should work correctly - persist and hydrate when options are specified on columns
    ✔ all types should work correctly - persist and hydrate when types are not specified on columns

  database schema > column types > postgres
    ✔ all types should work correctly - persist and hydrate
    ✔ all types should work correctly - persist and hydrate when options are specified on columns
    ✔ all types should work correctly - persist and hydrate when types are not specified on columns

  database schema > column types > postgres-enum
    ✔ should create table with ENUM column and save data to it
    ✔ should create ENUM column and revert creation
    ✔ should drop ENUM column and revert drop
    ✔ should create table with ENUM column and revert creation
    ✔ should drop table with ENUM column and revert drop
    ✔ should change non-enum column in to ENUM and revert change
    ✔ should change ENUM column in to non-enum and revert change
    ✔ should change ENUM array column in to non-array and revert change
    ✔ should change ENUM value and revert change
    ✔ should change `enumName` and revert change
    ✔ should not create new type if same `enumName` is used more than once
    ✔ should change both ENUM value and ENUM name and revert change
    ✔ should rename ENUM when column renamed and revert rename
    ✔ should rename ENUM when table renamed and revert rename

  database schema > column types > sap
    ✔ all types should work correctly - persist and hydrate
    ✔ all types should work correctly - persist and hydrate when options are specified on columns
    ✔ all types should work correctly - persist and hydrate when types are not specified on columns

  database schema > column types > spanner
    ✔ all types should work correctly - persist and hydrate
    ✔ all types should work correctly - persist and hydrate when options are specified on columns
    ✔ all types should work correctly - persist and hydrate when types are not specified on columns

  database schema > column types > sqlite
    ✔ all types should work correctly - persist and hydrate
    ✔ all types should work correctly - persist and hydrate when types are not specified on columns

  database schema > column width
    ✔ all types should be created with correct width
npm WARN deprecated @sinonjs/fake-timers@10.2.0: Use version 10.1.0. Version 10.2.0 has potential breaking issues
    ✔ should update data type display width (138ms)

  database schema > custom constraint names > foreign key
    ✔ should set custom constraint names
packages/integration-tests build: Done
npm WARN deprecated uuid@3.4.0: Please upgrade  to version 7 or higher.  Older versions may use Math.random() in certain circumstances, which is known to be problematic.  See https://v8.dev/blog/math-random for details.
npm WARN deprecated debug@3.2.6: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)
    ✔ should load constraints with custom names
    - should not change constraint names when table renamed
    - should not change constraint names when column renamed

  database schema > custom constraint names > index
    ✔ should set custom constraint names
    ✔ should load constraints with custom names
    ✔ should not change constraint names when table renamed (49ms)
    ✔ should not change constraint names when column renamed (42ms)

  database schema > custom constraint names > primary key
    ✔ should set custom constraint names
    ✔ should load constraints with custom names
    ✔ should not change constraint names when table renamed
    ✔ should not change constraint names when column renamed

  database schema > custom constraint names > unique
    ✔ should set custom constraint names
    ✔ should load constraints with custom names
    ✔ should not change constraint names when table renamed (44ms)
    ✔ should not change constraint names when column renamed

  database schema > enums
    ✔ should correctly use default values
    ✔ should correctly save and retrieve
    ✔ should not generate queries when no model changes

  database schema > enum arrays
    ✔ should correctly create default values
    ✔ should correctly save and retrieve

  database schema > generated columns > cockroachdb
    ✔ should not generate queries when no model changes
    ✔ should create table with generated columns
    ✔ should add generated column and revert add
    ✔ should drop generated column and revert drop
    ✔ should change generated column and revert change
    ✔ should remove data from 'typeorm_metadata' when table dropped

  database schema > generated columns > mssql
    ✔ should not generate queries when no model changes
    ✔ should create table with generated columns
    ✔ should add generated column and revert add
    ✔ should drop generated column and revert drop
    ✔ should change generated column and revert change
    ✔ should remove data from 'typeorm_metadata' when table dropped

  database schema > generated columns > mysql
    ✔ should not generate queries when no model changes
    ✔ should create table with generated columns
    - should add generated column and revert add
    - should drop generated column and revert drop
    - should change generated column and revert change
    ✔ should remove data from 'typeorm_metadata' when table dropped (108ms)

  database schema > generated columns > oracle
    ✔ should not generate queries when no model changes
    ✔ should create table with generated columns
    ✔ should add generated column and revert add
    ✔ should drop generated column and revert drop
    ✔ should change generated column and revert change
    ✔ should remove data from 'typeorm_metadata' when table dropped

  database schema > generated columns > postgres
    ✔ should not generate queries when no model changes
    ✔ should create table with generated columns
    ✔ should add generated column and revert add
    ✔ should drop generated column and revert drop
    ✔ should change generated column and revert change
    ✔ should remove data from 'typeorm_metadata' when table dropped

  database schema > generated columns > spanner
    ✔ should not generate queries when no model changes
    ✔ should create table with generated columns
    ✔ should add generated column and revert add
    ✔ should drop generated column and revert drop
    ✔ should change generated column and revert change
    ✔ should remove data from 'typeorm_metadata' when table dropped

  database schema > generated columns > sqlite
    ✔ should not generate queries when no model changes
    ✔ should create table with generated columns
    ✔ should add generated column and revert add
    ✔ should drop generated column and revert drop
    ✔ should change generated column and revert change
    ✔ should remove data from 'typeorm_metadata' when table dropped

  database schema > indices > reading index from entity and updating database
    ✔ should create a non unique index with 2 columns
packages/client build: Analysis will use the bundled TypeScript version 5.0.4
    ✔ should update the index to be unique (1396ms)

> sequelize@0.0.0-development prepare
> npm run build && husky install


> sequelize@0.0.0-development build
> node ./build.js

Compiling sequelize...
    ✔ should update the index swapping the 2 columns (1390ms)

  database schema > mssql-parameters
    ✔ should correctly insert/update/delete entities on SqlServer driver

  database-schema > rowid-column
    ✔ should create `rowid` generated column

  sequences > creating a sequence and marking the column as generated
    create table and check that primary key column is marked as generated
      ✔ should check that the primary key column is generated automatically

  database schema > simple-enums
    ✔ should correctly use default values
    ✔ should correctly save and retrieve

  database schema > simple enum arrays
    ✔ should correctly create default values
    ✔ should correctly save and retrieve

  decorators > embedded
    basic functionality
      ✔ should persist and load entities with embeddeds properly
      ✔ should be used with prop

  query builder > relation-count-decorator-many-to-many > many-to-many
    ✔ should load relation count on owner side
    ✔ should load relation count on owner side with limitation (42ms)
    ✔ should load relation count on owner side with additional conditions (66ms)
    ✔ should load relation count on both sides of relation (41ms)
    ✔ should load relation count on inverse side (46ms)
    ✔ should load relation count on inverse side with limitation (39ms)
packages/client build: Writing package typings: /home/jenkins/agent/workspace/pingcap/tidb/merged_integration_nodejs_test/tidb-test/prisma_test/prisma-4.16.x/packages/client/runtime/index.d.ts
    ✔ should load relation count on inverse side with additional conditions (40ms)

  decorators > relation-count-decorator > one-to-many
.git can't be found (see https://git.io/Jc3F9)
npm ERR! code 1
npm ERR! path /home/jenkins/agent/workspace/pingcap/tidb/merged_integration_nodejs_test/tidb-test/sequelize_test/sequelize_v6_test
npm ERR! command failed
npm ERR! command sh -c npm run build && husky install

npm ERR! A complete log of this run can be found in:
npm ERR!     /root/.npm/_logs/2024-05-17T15_34_07_651Z-debug-0.log
    ✔ should load relation count (49ms)

  decorators > relation-id-decorator > many-to-many
    ✔ should load ids when RelationId decorator used on owner side
tidb-server(PID: 303) started
loading test data to db ...
    ✔ should load ids when RelationId decorator used on owner side with additional condition

> sequelize@0.0.0-development build
> node ./build.js

    ✔ should load ids when RelationId decorator used on owner side without inverse side
Compiling sequelize...
    ✔ should load ids when RelationId decorator used on owner side without inverse side and with additional condition
    ✔ should load ids when RelationId decorator used on inverse side
    ✔ should load ids when RelationId decorator used on inverse side with additional condition
    ✔ should load ids when RelationId decorator used on nested relation (55ms)
    ✔ should not load ids of nested relations when RelationId decorator used on inherit relation and parent relation was not found
packages/client build: Analysis will use the bundled TypeScript version 5.0.4
    ✔ should load ids when RelationId decorator used on nested relation with additional conditions (70ms)

  decorators > relation-id-decorator > many-to-one

> sequelize@0.0.0-development teaser
> node test/teaser.js

###########################
# Running tests for mysql #
###########################

> sequelize@0.0.0-development test-integration
> yarn mocha --timeout 60000 --exit "test/integration/**/*.test.[tj]s"

yarn run v1.22.19
$ mocha -r ./test/registerEsbuild --timeout 60000 --exit 'test/integration/**/*.test.[tj]s'


  [MYSQL] Alias
    ✓ should uppercase the first letter in alias getter, but not in eager loading (118ms)
    ✓ shouldnt touch the passed alias (77ms)
    ✓ should allow me to pass my own plural and singular forms to hasMany (73ms)
    ✓ should allow me to define plural and singular forms on the model (68ms)

  [MYSQL] BelongsToMany
    getAssociations
      - supports transactions
      ✓ gets all associated objects with all fields
      ✓ gets all associated objects when no options are passed
packages/client build: Writing package typings: /home/jenkins/agent/workspace/pingcap/tidb/merged_integration_nodejs_test/tidb-test/prisma_test/prisma-4.16.x/packages/client/runtime/index-browser.d.ts
      ✓ only get objects that fulfill the options
      ✓ supports a where not in
    ✔ should load ids when RelationId decorator used

  decorators > relation-id > one-to-many
      ✓ supports a where not in on the primary key
      ✓ only gets objects that fulfill options with a formatted value
      ✓ get associated objects with an eager load
    ✔ should load id when RelationId decorator used
      ✓ get associated objects with an eager load with conditions but not required (50ms)
packages/client build: Done
packages/cli build$ node -r esbuild-register helpers/build.ts
packages/react-prisma build$ node -r esbuild-register helpers/build.ts
      ✓ should support schemas (214ms)
      ✓ supports custom primary keys and foreign keys (245ms)
    ✔ should load id when RelationId decorator used with additional condition

  decorators > relation-id > one-to-one
    ✔ should load ids when loadRelationIdAndMap used on owner side
      ✓ supports primary key attributes with different field and attribute names (246ms)
    ✔ should load id when loadRelationIdAndMap used on inverse side

  deferrable uq constraints should be check at the end of transaction
    ✔ use initially deferred deferrable uq constraints
    ✔ use initially immediated deferrable uq constraints

  deferrable fk constraints should be check at the end of transaction (#2191)
    ✔ use initially deferred deferrable fk constraints
    ✔ use initially immediated deferrable fk constraints

  MongoDriver
    connection string
      ✔ should create a connection string for replica sets (147ms)
      ✔ should create a connection string for non replica sets

  escape sqlite query parameters
    ✔ should transform boolean parameters with value `true` into `1`
    ✔ should transform boolean parameters with value `false` into `0`
    ✔ should transform boolean nativeParameters with value `true` into `1`
    ✔ should transform boolean nativeParameters with value `false` into 0

  option nativeBinding for better-sqlite3
    ✔ should use a the path set in nativeBindings to the node file

  driver > convert raw results to entity
    ✔ should return null value in entity property when record column is null
    ✔ should return true in entity property when record column is true
    ✔ should return false in entity property when record column is false

  DriverUtils
    parse mongo url
      ✔ should return a mongo url with a replica set
      ✔ should return a mongo url without a replica set

  postgres specific options
    ✔ should set application_name

  embedded > basic functionality
    ✔ should insert, load, update and remove entities with embeddeds properly

  other issues > entity listeners must work in embeddeds as well
    ✔ getters and setters should work correctly

  embedded > embedded-many-to-many-case1
    owner side
      ✔ should insert, load, update and remove entities with embeddeds when embedded entity having ManyToMany relation
    inverse side
      ✔ should insert, load, update and remove entities with embeddeds when embedded entity having ManyToMany relation

  embedded > embedded-many-to-many-case2
    owner side
      ✔ should insert, load, update and remove entities with embeddeds when embedded entity having ManyToMany relation (38ms)
    inverse side
packages/cli build: Done
packages/react-prisma build: Done
      ✔ should insert, load, update and remove entities with embeddeds when embedded entity having ManyToMany relation

  embedded > embedded-many-to-many-case3
    owner side
      ✔ should insert, load, update and remove entities with embeddeds when embedded entity having ManyToMany relation with multiple primary keys (one PK in each embed) (42ms)
    inverse side
      ✔ should insert, load, update and remove entities with embeddeds when embedded entity having ManyToMany relation with multiple primary keys (one PK in each embed) (39ms)

  embedded > embedded-many-to-many-case4
    owner side

> @prisma/integration-tests@0.0.0 test:tidb /home/jenkins/agent/workspace/pingcap/tidb/merged_integration_nodejs_test/tidb-test/prisma_test/prisma-4.16.x/packages/integration-tests
> jest integration.tidb --maxWorkers=1 --silent

      ✔ should insert, load, update and remove entities with embeddeds when embedded entity having ManyToMany relation with multiple primary keys (multiple keys in related entity) (42ms)
    inverse side
      ✔ should insert, load, update and remove entities with embeddeds when embedded entity having ManyToMany relation with multiple primary keys (multiple keys in related entity) (46ms)

  embedded > embedded-many-to-many-case5
    owner side
      ✓ supports non primary key attributes for joins (sourceKey only) (2924ms)
      ✔ should insert, load, update and remove entities with embeddeds when embedded entity having ManyToMany relation with multiple primary keys (multiple keys in both sides) (42ms)
    inverse side
      ✔ should insert, load, update and remove entities with embeddeds when embedded entity having ManyToMany relation with multiple primary keys (multiple keys in both sides) (46ms)

  embedded > embedded-many-to-one-case1
    owner side
      ✔ should insert, load, update and remove entities with embeddeds when embedded entity having ManyToOne relation
    inverse side
      ✓ supports non primary key attributes for joins (targetKey only) (2894ms)
      ✔ should insert, load, update and remove entities with embeddeds when embedded entity having ManyToOne relation

  embedded > embedded-many-to-one-case2
    owner side
      ✔ should insert, load, update and remove entities with embeddeds when embedded entity having ManyToOne relation
    inverse side
      ✓ supports non primary key attributes for joins (sourceKey and targetKey) (2875ms)
      ✔ should insert, load, update and remove entities with embeddeds when embedded entity having ManyToOne relation

  embedded > embedded-many-to-one-case3
    owner side
      ✔ should insert, load, update and remove entities with embeddeds when embedded entity having ManyToOne relation with multiple primary keys (one PK in each embed)
    inverse side
      ✔ should insert, load, update and remove entities with embeddeds when embedded entity having ManyToOne relation with multiple primary keys (one PK in each embed)

  embedded > embedded-many-to-one-case4
    owner side
      ✔ should insert, load, update and remove entities with embeddeds when embedded entity having ManyToOne relation with multiple primary keys (multiple keys in related entity)
    inverse side
      ✓ supports non primary key attributes for joins (custom through model) (4264ms)
      ✔ should insert, load, update and remove entities with embeddeds when embedded entity having ManyToOne relation with multiple primary keys (multiple keys in related entity)

  embedded > embedded-many-to-one-case5
    owner side
      ✔ should insert, load, update and remove entities with embeddeds when embedded entity having ManyToOne relation with multiple primary keys (multiple keys in both sides)
    inverse side
      ✓ supports non primary key attributes for joins for getting associations (sourceKey/targetKey) (2904ms)
      ✔ should insert, load, update and remove entities with embeddeds when embedded entity having ManyToOne relation with multiple primary keys (multiple keys in both sides) (43ms)

  embedded > embedded-one-to-one
    owner side
      ✔ should insert, load, update and remove entities with embeddeds when embedded entity having OneToOne relation
    inverse side
      - should insert, load, update and remove entities with embeddeds when embedded entity having OneToOne relation

  embedded > embedded-with-special-columns
    ✔ should insert, load, update and remove entities with embeddeds when embeds contains special columns (e.g. CreateDateColumn, UpdateDateColumn, DeleteDateColumn, VersionColumn (1019ms)

  embedded > multiple-primary-column
    ✔ should insert, load, update and remove entities with embeddeds when primary column defined in main and in embedded entities

  embedded > multiple-primary-columns-with-nested-embed
    ✔ should insert, load, update and remove entities with embeddeds when primary column defined in main and in embedded entities

  other issues > entity listeners must work in optional embeddeds as well
    ✔ getters and setters should work correctly

  embedded > outer-primary-column
    ✔ should insert, load, update and remove entities with embeddeds when primary column defined only in embedded entity

  embedded > prefix functionality
    ✔ should insert, load, update and remove entities with embeddeds properly

  entity-listeners
    ✔ beforeUpdate

  entity-metadata > create
    without entitySkipConstructor
      ✔ should call the constructor when creating an object
      ✔ should set the default property values
      ✔ should call the constructor when retrieving an object
    with entitySkipConstructor
      ✔ should call the constructor when creating an object
      ✔ should set the default property values when creating an object
      ✔ should not call the constructor when retrieving an object

  entity-metadata > property-map
      ✓ supports non primary key attributes for joins (custom foreignKey) (2900ms)
    ✔ should create correct property map object

  entity-metadata-validator
    ✔ should throw error if relation count decorator used with ManyToOne or OneToOne relations

  entity-metadata-validator > initialized relations
    ✔ should throw error if relation with initialized array was found on many-to-many relation
    ✔ should throw error if relation with initialized array was found on one-to-many relation
    ✔ should not throw error if relation with initialized array was not found
    ✔ should not throw error if relation with initialized array was found, but persistence for this relation was disabled

  entity-model
    ✔ should save successfully and use static methods successfully
    ✔ should reload given entity successfully (283ms)
    ✔ should reload exactly the same entity (280ms)
    upsert
      ✔ should upsert successfully

  entity schemas > basic functionality
    ✔ should perform basic operations with entity using repository
    ✔ should perform basic operations with entity using manager

  entity-schema > checks
    entity-schema > checks > postgres, cockroachdb, oracle, mssql
      ✔ should create a check constraints
    entity-schema > checks > spanner
      ✔ should create a check constraints

  entity-schema > columns > mysql
    ✔ should create columns with different options

  entity schema > custom constraint names > foreign key
PASS src/__tests__/integration/tidb/introspection.test.ts (18.951 s)
    ✔ should set custom constraint names
      ✓ supports non primary key attributes for joins (custom foreignKey, custom through model) (4228ms)
      ✓ supports primary key attributes with different field names where parent include is required (296ms)
    hasAssociations
      - supports transactions
      ✓ answers false if only some labels have been assigned
      ✓ answers false if only some labels have been assigned when passing a primary key instead of an object
      ✓ answers true if all label have been assigned
    ✔ should load constraints with custom names
    - should not change constraint names when table renamed
    - should not change constraint names when column renamed

  entity schema > custom constraint names > index
    ✔ should set custom constraint names
      ✓ answers true if all label have been assigned when passing a primary key instead of an object
    ✔ should load constraints with custom names
    ✔ should not change constraint names when table renamed (45ms)
    ✔ should not change constraint names when column renamed

  database schema > custom constraint names > primary key
    ✔ should set custom constraint names
    ✔ should load constraints with custom names
    ✔ should not change constraint names when table renamed
    ✔ should not change constraint names when column renamed

  database schema > custom constraint names > unique
    ✔ should set custom constraint names
    ✔ should load constraints with custom names
      ✓ answers true for labels that have been assigned multitple times (228ms)
    ✔ should not change constraint names when table renamed (47ms)
    ✔ should not change constraint names when column renamed

  entity-schema > embedded - class-instance
    ✔ should create an table
    ✔ should not create table with embedded
    ✔ should create embedded column name with prefix
    ✔ should create index for embedded

  entity-schema > embedded - class-instance
      ✓ answers true for labels that have been assigned multitple times when passing a primary key instead of an object (234ms)
    hasAssociations with binary key
    ✔ should save entity with embedded
    ✔ should contains instance of target class embedded entity

  entity-schema > embedded - plain-object
    ✔ should save entity with embedded
      ✓ answers true for labels that have been assigned
    ✔ should contains instance of plain object for embedded entity

  entity-schema > exclusions
    ✔ should create an exclusion constraint

  entity-schema > indices > basic
    ✔ should create a non unique index with 2 columns
      ✓ answer false for labels that have not been assigned
    countAssociations
      ✓ should count all associations
      ✓ should count filtered associations
      ✓ should count scoped associations
      ✓ should count scoped through associations
    setAssociations
      ✓ clears associations when passing null to the set-method (113ms)
    ✔ should update the index to be unique (1487ms)
      ✓ should be able to set twice with custom primary keys (111ms)
      ✓ joins an association with custom primary keys (107ms)
      ✓ supports passing the primary key instead of an object (115ms)
      ✓ using scope to set associations (148ms)
      ✓ updating association via set associations with scope (147ms)
    ✔ should update the index swaping the 2 columns (1403ms)

  entity-schema > indices > mysql
    - should correctly create SPATIAL and FULLTEXT indices

  entity schemas > target option
    ✔ should create instance of the target
    ✔ should find instances of the target

  entity-schema > uniques
    ✔ should create an unique constraint with 2 columns

  entity subscriber > query data
    ✔ passes query data to subscriber
    ✔ cleans up the data after the save completes

  entity subscriber > transaction flow
    ✔ transactionStart
    ✔ transactionCommit
    ✔ transactionRollback

  errors > prototype tree
    ✔ prototype tree makes sense

  find options > find operators > ArrayContainedBy
    ✔ should find entries in regular arrays
    ✔ should find entries in enum arrays

  find options > find operators > ArrayContains
    ✔ should find entries in regular arrays
    ✔ should find entries in enum arrays

  find options > find operators > ArrayOverlap
    ✔ should find entries in regular arrays
    ✔ should find entries in enum arrays

  find options > order
      ✓ should catch EmptyResultError when rejectOnEmpty is set (107ms)
    createAssociations
      ✓ creates a new associated object (108ms)
      - supports transactions
      ✓ supports setting through table attributes (114ms)
      ✓ supports using the field parameter (112ms)
    addAssociations
      ✓ supports both single instance and array (105ms)
      - supports transactions
      ✓ supports transactions when updating a through model (119ms)
      ✓ supports passing the primary key instead of an object (99ms)
    ✔ order by id DESC (51ms)
      ✓ should not pass indexes to the join table (2749ms)
      ✓ should catch EmptyResultError when rejectOnEmpty is set (126ms)
      ✓ should returns array of intermediate table (116ms)
    addMultipleAssociations
      ✓ supports both single instance and array (121ms)
      ✓ adds associations without removing the current ones (129ms)
    through model validations
      ✓ runs on add
      ✓ runs on set
      ✓ runs on create
    optimizations using bulk create, destroy and update
      ✓ uses one insert into statement
      ✓ uses one delete from statement
    ✔ order by title (45ms)
    join table creation
      ✓ should work with non integer primary keys (318ms)
      ✓ makes join table non-paranoid by default
      ✓ should allow creation of a paranoid join table
    foreign keys
      ✓ should correctly generate underscored keys
      ✓ should infer otherKey from paired BTM relationship with a through string defined
      ✓ should infer otherKey from paired BTM relationship with a through model defined
    foreign key with fields specified
      ✓ should correctly get associations even after a child instance is deleted (158ms)
      ✓ should correctly get associations when doubly linked (140ms)
PASS src/__tests__/integration/tidb/runtime.test.ts (17.657 s)

Test Suites: 2 passed, 2 total
Tests:       130 passed, 130 total
Snapshots:   130 passed, 130 total
Time:        37.082 s
prisma-4.16.x end
[Pipeline] }
Cache not saved (ws/jenkins-pingcap-tidb-merged_integration_nodejs_test-1175/tidb-test already exists)
      ✓ should be able to handle nested includes properly (211ms)
[Pipeline] // cache
[Pipeline] }
[Pipeline] // dir
[Pipeline] }
[Pipeline] // stage
[Pipeline] }
[Pipeline] // container
[Pipeline] }
[Pipeline] // withEnv
[Pipeline] }
[Pipeline] // node
[Pipeline] }
[Pipeline] // podTemplate
[Pipeline] }
    primary key handling for join table
      ✓ removes the primary key if it was added by sequelize
      ✓ keeps the primary key if it was added by the user
      without sync
        ✓ removes all associations
[Pipeline] // withEnv
[Pipeline] }
[Pipeline] // stage
[Pipeline] }
    through
      paranoid
        ✓ gets only non-deleted records by default
    ✔ where two criteria (42ms)
        ✓ returns both deleted and non-deleted records with paranoid=false
        ✓ hasAssociation also respects paranoid option
      fetching from join table
        ✓ should contain the data from the join table on .UserProjects a DAO
        ✓ should be able to alias the default name of the join table
        ✓ should be able to limit the join table attributes returned
      inserting in join table
        add
          ✓ should insert data provided on the object into the join table
          ✓ should insert data provided as a second argument into the join table
          ✓ should be able to add twice (second call result in UPDATE call) without any attributes (and timestamps off) on the through model (353ms)
    ✔ order by relation (45ms)
          ✓ should be able to add twice (second call result in UPDATE call) with custom primary keys and without any attributes (and timestamps off) on the through model (345ms)
          ✓ should be able to create an instance along with its many-to-many association which has an extra column in the junction table (384ms)
        set
          ✓ should be able to combine properties on the associated objects, and default values
          ✓ should be able to set twice (second call result in UPDATE calls) without any attributes (and timestamps off) on the through model (362ms)
        query with through.where
          ✓ should support query the through model
      removing from the join table
        ✓ should remove a single entry without any attributes (and timestamps off) on the through model (117ms)
        ✓ should remove multiple entries without any attributes (and timestamps off) on the through model (116ms)
    ✔ order by relation with where relation applied (43ms)
    belongsTo and hasMany at once
      source belongs to target
        ✓ correctly uses bId in A
      target belongs to source
        ✓ correctly uses bId in A
    alias
      ✓ creates the join table when through is a string (108ms)
      ✓ creates the join table when through is a model (108ms)
      ✓ correctly identifies its counterpart when through is a string
      ✓ correctly identifies its counterpart when through is a model
    multiple hasMany
      project has owners and users and owners and users have projects
        ✓ correctly sets user and owner
    Foreign key constraints
      ✓ can cascade deletes both ways by default (128ms)
      ✓ can restrict deletes both ways (123ms)
      ✓ can cascade and restrict deletes (129ms)
      ✓ should be possible to remove all constraints (108ms)
      ✓ create custom unique identifier (146ms)
    Association options
      ✓ should throw an error if foreignKey and as result in a name clash
      allows the user to provide an attribute definition object as foreignKey
        ✓ works when taking a column directly from the object
    thisAssociations
      ✓ should work with this reference (88ms)
      ✓ should work with custom this reference (126ms)
    ✔ order by nested relations (47ms)
      ✓ should setup correct foreign keys
    Eager loading
      ✓ should load with an alias (122ms)
      ✓ should load all (123ms)

  [MYSQL] BelongsTo
    Model.associations
      ✓ should store all associations when associating to the same table multiple times
    get
      multiple
        ✓ should fetch associations for multiple instances (86ms)
    getAssociation
      ✓ supports transactions (95ms)
      ✓ should be able to handle a where object that's a first class citizen. (79ms)
      ✓ supports schemas (87ms)
      ✓ supports schemas when defining custom foreign key attribute #9029 (90ms)
    setAssociation
      ✓ supports transactions (84ms)
      ✓ can set the association with declared primary keys... (84ms)
      ✓ clears the association if null is passed (88ms)
      ✓ should throw a ForeignKeyConstraintError if the associated record does not exist (84ms)
      ✓ supports passing the primary key instead of an object (83ms)
      ✓ should support logging (82ms)
      ✓ should not clobber atributes (76ms)
      ✓ should set the foreign key value without saving when using save: false (84ms)
      ✓ supports setting same association twice (78ms)
    createAssociation
      ✓ creates an associated model instance (86ms)
      ✓ supports transactions (88ms)
    foreign key
      ✓ should setup underscored field with foreign keys when using underscored
      ✓ should use model name when using camelcase
    ✔ order by complex nested relations (42ms)
      ✓ should support specifying the field of a foreign key (79ms)
      ✓ should set foreignKey on foreign table (179ms)
    foreign key constraints
      ✓ are enabled by default (83ms)
      ✓ sets to NO ACTION if allowNull: false (82ms)
      ✓ should be possible to disable them (73ms)
      ✓ can cascade deletes (88ms)
      ✓ can restrict deletes (101ms)
      ✓ can restrict updates (86ms)
      ✓ can cascade updates (81ms)
    association column
      ✓ has correct type and name for non-id primary keys with non-integer type (74ms)
      ✓ should support a non-primary key as the association column on a target without a primary key (88ms)
      ✓ should support a non-primary unique key as the association column (88ms)
      ✓ should support a non-primary key as the association column with a field option (82ms)
      ✓ should support a non-primary key as the association column in a table with a composite primary key (85ms)
    association options
      ✓ can specify data type for auto-generated relational keys (129ms)
    ✔ order by column in embed (42ms)
      ✓ should throw an error if foreignKey and as result in a name clash
      ✓ should throw an error if an association clashes with the name of an already define attribute
      allows the user to provide an attribute definition object as foreignKey
        ✓ works with a column that hasnt been defined before
        ✓ works when taking a column directly from the object
        ✓ works when merging with an existing definition
    Eager loading
      ✓ should load with an alias (84ms)
      ✓ should load all (85ms)

  [MYSQL] HasMany
    Model.associations
      ✓ should store all assocations when associting to the same table multiple times
    count
      ✓ should not fail due to ambiguous field (93ms)
    get
      multiple
        ✓ should fetch associations for multiple instances (91ms)
        ✓ should fetch associations for multiple instances with limit and order (93ms)
        ✓ should fetch multiple layers of associations with limit and order with separate=true (157ms)
        ✓ should fetch associations for multiple instances with limit and order and a belongsTo relation (144ms)
        ✓ supports schemas (158ms)
    (1:N)
      ✓ clears associations when passing null to the set-method with omitNull set to true (118ms)
      hasAssociation
        ✓ should only generate one set of foreignKeys
    ✔ order by relation in embed (45ms)

  find options > relations
        ✓ supports transactions (188ms)
        ✓ does not have any labels assigned to it initially
        ✓ answers true if the label has been assigned
        ✓ answers correctly if the label has been assigned when passing a primary key instead of an object
      hasAssociations
        ✓ supports transactions (186ms)
        ✓ answers false if only some labels have been assigned
        ✓ answers false if only some labels have been assigned when passing a primary key instead of an object
        ✓ answers true if all label have been assigned
        ✓ answers true if all label have been assigned when passing a primary key instead of an object
      setAssociations
        ✓ supports transactions (91ms)
        ✓ clears associations when passing null to the set-method (94ms)
        ✓ supports passing the primary key instead of an object (107ms)
      addAssociations
        ✓ supports transactions (89ms)
        ✓ supports passing the primary key instead of an object (95ms)
      addMultipleAssociations
        ✓ adds associations without removing the current ones (97ms)
    ✔ basic relation (43ms)
        ✓ handles decent sized bulk creates (193ms)
      createAssociations
        ✓ creates a new associated object (92ms)
        ✓ creates the object with the association directly (103ms)
        ✓ supports transactions (92ms)
        ✓ supports passing the field option (88ms)
      getting assocations with options
        ✓ should treat the where object of associations as a first class citizen (281ms)
        ✓ gets all associated objects when no options are passed
        ✓ only get objects that fulfill the options
      countAssociations
        ✓ should count all associations
        ✓ should count filtered associations
        ✓ should count scoped associations
      thisAssociations
        ✓ should work with alias (45ms)
    foreign key constraints
      1:m
        ✓ sets null by default (94ms)
    ✔ complex relation #1 (42ms)
        ✓ sets to CASCADE if allowNull: false (94ms)
        ✓ should be possible to remove all constraints (83ms)
        ✓ can cascade deletes (93ms)
        ✓ can cascade updates (95ms)
        ✓ can restrict deletes (92ms)
        ✓ can restrict updates (91ms)
    Association options
      ✓ should setup underscored field with foreign keys when using underscored
      ✓ should use model name when using camelcase
      ✓ can specify data type for auto-generated relational keys (104ms)
      ✓ infers the keyType if none provided (79ms)
      ✓ should throw an error if foreignKey and as result in a name clash
(node:776) [SEQUELIZE0005] DeprecationWarning: Passing a double nested nested array to `group` is unsupported and will be removed in v6.
(Use `node --trace-deprecation ...` to show where the warning was created)
      ✓ should ignore group from ancestor on deep separated query (166ms)
      allows the user to provide an attribute definition object as foreignKey
        ✓ works with a column that hasnt been defined before
        ✓ works when taking a column directly from the object
        ✓ works when merging with an existing definition
    sourceKey
      ✓ should use sourceKey
    ✔ complex relation #2 (42ms)
      ✓ should count related records
      ✓ should set right field when add relative
    ✔ relation in embed (45ms)

  find options > select
      ✓ should create with nested associated models
    ✔ select id (47ms)
      ✓ should create nested associations with symmetric getters/setters on FK (1617ms)
    sourceKey with where clause in include
      ✓ should use the specified sourceKey instead of the primary key
    Eager loading
      ✓ should load with an alias (95ms)
    ✔ select title (43ms)
      ✓ should load all (90ms)

  [MYSQL] HasOne
    Model.associations
      ✓ should store all associations when associating to the same table multiple times
    get
      multiple
        ✓ should fetch associations for multiple instances (103ms)
    getAssociation
      ✓ supports transactions (102ms)
      ✓ should be able to handle a where object that's a first class citizen. (94ms)
      ✓ supports schemas (96ms)
    setAssociation
      ✓ supports transactions (92ms)
      ✓ can set an association with predefined primary keys (93ms)
      ✓ clears the association if null is passed (92ms)
      ✓ should throw a ForeignKeyConstraintError if the associated record does not exist (85ms)
      ✓ supports passing the primary key instead of an object (92ms)
      ✓ supports updating with a primary key instead of an object (95ms)
      ✓ supports setting same association twice (96ms)
    createAssociation
      ✓ creates an associated model instance (89ms)
      ✓ supports transactions (93ms)
    foreign key
      ✓ should setup underscored field with foreign keys when using underscored
      ✓ should use model name when using camelcase
      ✓ should support specifying the field of a foreign key (88ms)
      ✓ should support custom primary key field name in sub queries (82ms)
    foreign key constraints
      ✓ are enabled by default (80ms)
      ✓ sets to CASCADE if allowNull: false (79ms)
      ✓ should be possible to disable them (76ms)
      ✓ can cascade deletes (82ms)
    ✔ select title and text (43ms)
      ✓ works when cascading a delete with hooks but there is no associate (i.e. "has zero") (80ms)
      ✓ can cascade updates (80ms)
      ✓ can restrict deletes (81ms)
      ✓ can restrict updates (86ms)
    association column
      ✓ has correct type for non-id primary keys with non-integer type (74ms)
      ✓ should support a non-primary key as the association column on a target with custom primary key (91ms)
      ✓ should support a non-primary unique key as the association column (84ms)
      ✓ should support a non-primary unique key as the association column with a field option (97ms)
    Association options
      ✓ can specify data type for autogenerated relational keys (78ms)
      ✓ should throw an error if an association clashes with the name of an already define attribute
      allows the user to provide an attribute definition object as foreignKey
        ✓ works with a column that hasnt been defined before
        ✓ works when taking a column directly from the object
        ✓ works when merging with an existing definition
    Counter part
      BelongsTo
        ✓ should only generate one foreign key
    Eager loading
      ✓ should load with an alias (86ms)
      ✓ should load all (83ms)

  [MYSQL] Multiple Level Filters
    ✓ can filter through belongsTo (130ms)
    ✓ avoids duplicated tables in query (126ms)
    ✔ select column in embed (38ms)

  find options > where
    ✓ can filter through hasMany (137ms)
    ✓ can filter through hasMany connector (121ms)

  [MYSQL] associations
    scope
      1:1
        ✓ should create, find and include associations with scope values (151ms)
        ✓ should create included association with scope values (136ms)
      1:M
        ✓ should create, find and include associations with scope values (148ms)
        ✓ should make the same query if called multiple time (#4470) (139ms)
        ✓ should created included association with scope values (133ms)
        ✓ should include associations with operator scope values (133ms)
        ✓ should not mutate scope when running SELECT query (#12868) (130ms)
      N:M
        on the target
          ✓ [Flaky] should create, find and include associations with scope values (120ms)
        on the through model
          ✓ should create, find and include associations with scope values (245ms)
    ✔ where id (39ms)

  [MYSQL] Self
    ✓ supports freezeTableName (40ms)
    ✓ can handle 1:m associations (49ms)
    ✓ can handle n:m associations (87ms)
    ✓ can handle n:m associations with pre-defined through table (85ms)

  [MYSQL] CLS (Async hooks)
    ✓ CLS namespace is stored in Sequelize._cls
    ✓ promises returned by sequelize.query are correctly patched
    ✓ custom logging with benchmarking has correct CLS context (505ms)
    context
      ✓ does not use continuation storage on manually managed transactions
      ✓ supports several concurrent transactions
      ✓ supports nested promise chains
      ✓ does not leak variables to the outer scope (502ms)
      ✓ does not leak variables to the following promise chain
      ✓ does not leak outside findOrCreate
    sequelize.query integration
      ✓ automagically uses the transaction in all calls
      ✓ automagically uses the transaction in all calls with async/await
    Model Hook integration
      ✓ passes the transaction to hooks {beforeBulkCreate,beforeCreate,afterCreate,afterBulkCreate} when calling Model.bulkCreate
      ✓ passes the transaction to hooks {beforeFind,beforeFindAfterExpandIncludeAll,beforeFindAfterOptions} when calling Model.findAll
      ✓ passes the transaction to hooks {afterFind} when calling Model.findAll
      ✓ passes the transaction to hooks {beforeCount} when calling Model.count
      ✓ passes the transaction to hooks {beforeUpsert,afterUpsert} when calling Model.upsert
      ✓ passes the transaction to hooks {beforeBulkDestroy,afterBulkDestroy} when calling Model.destroy
      ✓ passes the transaction to hooks {beforeDestroy,beforeDestroy} when calling Model.destroy with individualHooks
      ✓ passes the transaction to hooks {beforeDestroy,beforeDestroy} when calling Model#destroy
      ✓ passes the transaction to hooks {beforeBulkUpdate,afterBulkUpdate} when calling Model.update
    ✔ where title (41ms)
      ✓ passes the transaction to hooks {beforeUpdate,afterUpdate} when calling Model.update with individualHooks
      ✓ passes the transaction to hooks {beforeCreate,afterCreate} when calling Model#save (isNewRecord)
      ✓ passes the transaction to hooks {beforeUpdate,afterUpdate} when calling Model#save (!isNewRecord)
      paranoid restore
        ✓ passes the transaction to hooks {beforeBulkRestore,afterBulkRestore} when calling Model.restore
        ✓ passes the transaction to hooks {beforeRestore,afterRestore} when calling Model.restore with individualHooks
        ✓ passes the transaction to hooks {beforeRestore,afterRestore} when calling Model#restore

  [MYSQL] Configuration
    Connections problems should fail with a nice message
      ✓ when we don't have the correct server details
      ✓ when we don't have the correct login information
      ✓ when we don't have a valid dialect.

  [MYSQL] DataTypes
    ✓ allows me to return values from a custom parse function (39ms)
    ✓ calls parse and stringify for JSON
    ✓ calls parse and stringify for DATE
    ✓ calls parse and stringify for DATEONLY
    ✓ calls parse and stringify for TIME
    ✓ calls parse and stringify for BLOB
    ✓ calls parse and stringify for CHAR
    ✓ calls parse and stringify/bindParam for STRING
    ✓ calls parse and stringify for TEXT
    ✓ calls parse and stringify for BOOLEAN
    ✓ calls parse and stringify for INTEGER
    ✓ calls parse and stringify for DECIMAL
    ✓ calls parse and stringify for BIGINT
    ✓ should handle JS BigInt type
    ✓ should handle TINYINT booleans
    ✓ calls parse and bindParam for DOUBLE
    ✓ calls parse and bindParam for FLOAT
    ✓ calls parse and bindParam for REAL
    ✓ calls parse and stringify for UUID
    ✓ calls parse and stringify for CIDR
    ✓ calls parse and stringify for INET
    ✓ calls parse and stringify for CITEXT
    ✓ calls parse and stringify for MACADDR
    ✓ calls parse and stringify for ENUM
    ✓ should parse DECIMAL as string
    ✓ should parse BIGINT as string
    ✓ should allow spaces in ENUM
    ✓ should return YYYY-MM-DD format string for DATEONLY
    ✓ should return set DATEONLY field to NULL correctly (38ms)
    ✓ should be able to cast buffer as boolean

  [MYSQL] Connection Manager
    ✓ should initialize a single pool without replication
    ✓ should initialize a multiple pools with replication
    ✓ should round robin calls to the read pool
    ✓ should trigger deprecation for non supported engine version
    ✓ should allow forced reads from the write pool
    ✓ should clear the pool after draining it

  [MYSQL Specific] Associations
    many-to-many
      where tables have the same prefix
        ✓ should create a table wp_table1wp_table2s (55ms)
      when join table name is specified
        ✓ should not use only a specified name
    HasMany
      addDAO / getModel
    ✔ where two criteria (38ms)
        ✓ should correctly add an association to the dao
      removeDAO
        ✓ should correctly remove associated objects

  [MYSQL Specific] Connection Manager
    ✓ -FOUND_ROWS can be suppressed to get back legacy behavior
    ✓ should acquire a valid connection when keepDefaultTimezone is true

  [MYSQL Specific] DAOFactory
    constructor
      ✓ handles extended attributes (unique)
      ✓ handles extended attributes (default)
      ✓ handles extended attributes (null)
      ✓ handles extended attributes (primaryKey)
      ✓ adds timestamps
      ✓ adds deletedAt if paranoid
      ✓ underscores timestamps if underscored
      ✓ omits text fields with defaultValues
      ✓ omits blobs fields with defaultValues
    primaryKeys
      ✓ determines the correct primaryKeys

  [MYSQL Specific] Errors
    ForeignKeyConstraintError
      ✓ in context of DELETE restriction (118ms)
      ✓ in context of missing relation (105ms)

  [MYSQL] Warning
    logging
Executing (default): DROP TABLE IF EXISTS `models`;
Executing (default): SHOW WARNINGS
MySQL Warnings (default): Unknown table 'sequelize_test.models'; Unknown table 'sequelize_test.models'
Executing (default): SELECT CONSTRAINT_NAME as constraint_name,CONSTRAINT_NAME as constraintName,CONSTRAINT_SCHEMA as constraintSchema,CONSTRAINT_SCHEMA as constraintCatalog,TABLE_NAME as tableName,TABLE_SCHEMA as tableSchema,TABLE_SCHEMA as tableCatalog,COLUMN_NAME as columnName,REFERENCED_TABLE_SCHEMA as referencedTableSchema,REFERENCED_TABLE_SCHEMA as referencedTableCatalog,REFERENCED_TABLE_NAME as referencedTableName,REFERENCED_COLUMN_NAME as referencedColumnName FROM INFORMATION_SCHEMA.KEY_COLUMN_USAGE where TABLE_NAME = 'models' AND CONSTRAINT_NAME!='PRIMARY' AND CONSTRAINT_SCHEMA='sequelize_test' AND REFERENCED_TABLE_NAME IS NOT NULL;
Executing (default): DROP TABLE IF EXISTS `models`;
Executing (default): SHOW WARNINGS
MySQL Warnings (default): Unknown table 'sequelize_test.models'; Unknown table 'sequelize_test.models'
Executing (default): DROP TABLE IF EXISTS `models`;
Executing (default): SHOW WARNINGS
MySQL Warnings (default): Unknown table 'sequelize_test.models'; Unknown table 'sequelize_test.models'
Executing (default): CREATE TABLE IF NOT EXISTS `models` (`id` INTEGER NOT NULL auto_increment , `name` VARCHAR(1) BINARY, `createdAt` DATETIME NOT NULL, `updatedAt` DATETIME NOT NULL, PRIMARY KEY (`id`)) ENGINE=InnoDB;
Executing (default): SHOW INDEX FROM `models`
Executing (default): SELECT 1+1 AS result
Executing (default): SET SESSION sql_mode='';
Executing (default): INSERT INTO `models` (`id`,`name`,`createdAt`,`updatedAt`) VALUES (DEFAULT,?,?,?);
Executing (default): SHOW WARNINGS
MySQL Warnings (default): 
      ✓ logs warnings when there are warnings (42ms)

  [MYSQL] Sequelize Errors
    API Surface
      ✓ Should have the Error constructors exposed
      ✓ Sequelize Errors instances should be instances of Error
      ✓ SequelizeValidationError should find errors by path
      ✓ SequelizeValidationError should override message property when message parameter is specified
      ✓ SequelizeValidationError should concatenate an error messages from given errors if no explicit message is defined
      ✓ SequelizeValidationErrorItem does not require instance & validator constructor parameters
      ✓ SequelizeValidationErrorItem should have instance, key & validator properties when given to constructor
      ✓ SequelizeValidationErrorItem.getValidatorKey() should return a string
      ✓ SequelizeValidationErrorItem.getValidatorKey() should throw if namespace separator is invalid (only if NS is used & available)
      ✓ SequelizeValidationErrorItem should map deprecated "type" values to new "origin" values
      ✓ SequelizeValidationErrorItemOrigin is valid
      ✓ SequelizeValidationErrorItem.Origins is valid
      ✓ SequelizeDatabaseError should keep original message
      ✓ SequelizeDatabaseError should keep the original sql and the parameters
      ✓ ConnectionError should keep original message
      ✓ ConnectionRefusedError should keep original message
      ✓ AccessDeniedError should keep original message
      ✓ HostNotFoundError should keep original message
      ✓ HostNotReachableError should keep original message
      ✓ InvalidConnectionError should keep original message
      ✓ ConnectionTimedOutError should keep original message
    OptimisticLockError
      ✓ got correct error type and message (39ms)
    ConstraintError
      ✓ Can be intercepted as UniqueConstraintError using .catch (38ms)
      ✓ Can be intercepted as ValidationError using .catch
      ✓ Supports newlines in keys
      ✓ Works when unique keys are not defined in sequelize
      ✓ adds parent and sql properties

  [MYSQL] Hooks
    associations
      1:1
        cascade onUpdate
          ✓ on success
          ✓ on error
        cascade onDelete
          #remove
            ✓ with no errors
    ✔ where two criteria without match (38ms)
            ✓ with errors
        no cascade update
          ✓ on success
          ✓ on error
        no cascade delete
          #remove
            ✓ with no errors
            ✓ with errors
      1:M
        cascade
          #remove
            ✓ with no errors
            ✓ with errors
        no cascade
          #remove
            ✓ with no errors
            ✓ with errors
      M:M
        cascade
          #remove
            ✓ with no errors
            ✓ with errors
    ✔ where relation (41ms)
        no cascade
          #remove
            ✓ with no errors
            ✓ with errors
      multiple 1:M
        cascade
          #remove
            ✓ with no errors
            ✓ with errors
      multiple 1:M sequential hooks
        cascade
          #remove
            ✓ with no errors
    ✔ where column and relation (39ms)
            ✓ with errors

  [MYSQL] Hooks
    #bulkCreate
      on success
        ✓ should run hooks
      on error
        ✓ should return an error from before
        ✓ should return an error from after
      with the {individualHooks: true} option
        ✓ should run the afterCreate/beforeCreate functions for each item created successfully
        ✓ should run the afterCreate/beforeCreate functions for each item created with an error
    #bulkUpdate
      on success
        ✓ should run hooks
      on error
        ✓ should return an error from before
        ✓ should return an error from after
      with the {individualHooks: true} option
        ✓ should run the after/before functions for each item created successfully
        ✓ should run the after/before functions for each item created successfully changing some data before updating
        ✓ should run the after/before functions for each item created with an error
    #bulkDestroy
      on success
        ✓ should run hooks
      on error
        ✓ should return an error from before
        ✓ should return an error from after
    ✔ where nested relations (44ms)
      with the {individualHooks: true} option
        ✓ should run the after/before functions for each item created successfully
        ✓ should run the after/before functions for each item created with an error
    #bulkRestore
      on success
        ✓ should run hooks
      on error
        ✓ should return an error from before
        ✓ should return an error from after
      with the {individualHooks: true} option
        ✓ should run the after/before functions for each item restored successfully
        ✓ should run the after/before functions for each item restored with an error

  [MYSQL] Hooks
    #count
      on success
        ✓ hook runs
        ✓ beforeCount hook can change options
      on error
        ✓ in beforeCount hook returns error

  [MYSQL] Hooks
    #create
      ✓ should not trigger hooks on parent when using N:M association setters (184ms)
      on success
        ✓ should run hooks
      on error
        ✓ should return an error from before
        ✓ should return an error from after
      preserves changes to instance
        ✓ beforeValidate
        ✓ afterValidate
        ✓ beforeCreate
        ✓ beforeSave
        ✓ beforeSave with beforeCreate

  [MYSQL] Hooks
    #destroy
      on success
        ✓ should run hooks
      on error
        ✓ should return an error from before
        ✓ should return an error from after
      with paranoid mode enabled
        ✓ sets other changed values when soft deleting and a beforeDestroy hooks kicks in
        ✓ should not throw error when a beforeDestroy hook changes a virtual column

  [MYSQL] Hooks
    #find
      ✓ allow changing attributes via beforeFind #5675
      on success
        ✓ all hooks run
        ✓ beforeFind hook can change options
        ✓ beforeFindAfterExpandIncludeAll hook can change options
        ✓ beforeFindAfterOptions hook can change options
        ✓ afterFind hook can change results
      on error
        ✓ in beforeFind hook returns error
        ✓ in beforeFindAfterExpandIncludeAll hook returns error
    ✔ where complex nested relations (43ms)
        ✓ in beforeFindAfterOptions hook returns error
        ✓ in afterFind hook returns error

  [MYSQL] Hooks
    #define
      ✓ beforeDefine hook can change model name
      ✓ beforeDefine hook can alter options
      ✓ beforeDefine hook can alter attributes
      ✓ afterDefine hook can alter options
    #init
      ✓ beforeInit hook can alter config
      ✓ beforeInit hook can alter options
      ✓ afterInit hook can alter options
    passing DAO instances
      beforeValidate / afterValidate
        ✓ should pass a DAO instance to the hook (72ms)
      beforeCreate / afterCreate
        ✓ should pass a DAO instance to the hook (71ms)
      beforeDestroy / afterDestroy
        ✓ should pass a DAO instance to the hook (73ms)
      beforeUpdate / afterUpdate
        ✓ should pass a DAO instance to the hook (76ms)
    Model#sync
      on success
        ✓ should run hooks
        ✓ should not run hooks when "hooks = false" option passed
      on error
        ✓ should return an error from before
        ✓ should return an error from after
    sequelize#sync
      on success
        ✓ should run hooks
        ✓ should not run hooks if "hooks = false" option passed
      on error
        ✓ should return an error from before
        ✓ should return an error from after
    #removal
      ✓ should be able to remove by name
      ✓ should be able to remove by reference
    ✔ where or + optional relations (40ms)
      ✓ should be able to remove proxies
    Sequelize hooks
      ✓ should run before/afterPoolAcquire hooks

  [MYSQL] Hooks
    #restore
      on success
        ✓ should run hooks
      on error
        ✓ should return an error from before
        ✓ should return an error from after

  [MYSQL] Hooks
    #update
      on success
        ✓ should run hooks
      on error
        ✓ should return an error from before
        ✓ should return an error from after
      preserves changes to instance
        ✓ beforeValidate
        ✓ afterValidate
        ✓ beforeSave
        ✓ beforeSave with beforeUpdate

  [MYSQL] Hooks
    #upsert
      on success
        ✓ should run hooks
      on error
        ✓ should return an error from before
        ✓ should return an error from after
      preserves changes to values
        ✓ beforeUpsert

  [MYSQL] Hooks
    #validate
      #create
        ✓ should return the user
      #3534, hooks modifications
        ✓ fields modified in hooks are saved
      on error
        ✓ should emit an error from after hook
        ✓ should call validationFailed hook
        ✓ should not replace the validation error in validationFailed hook by default
        ✓ should replace the validation error if validationFailed hook creates a new error

  [MYSQL] Include
    find
      ✓ should support an empty belongsTo include (86ms)
      ✓ should support a belongsTo association reference (89ms)
      ✓ should support to use associations with Sequelize.col (129ms)
      ✓ should support a belongsTo association reference with a where (84ms)
      ✓ should support a empty hasOne include (79ms)
    ✔ where column in embed
      ✓ should support a hasOne association reference (82ms)
      ✓ should support including a belongsTo association rather than a model/as pair (91ms)
      ✓ should support a hasMany association reference (83ms)
      ✓ should support a hasMany association reference with a where condition (91ms)
      ✓ should support a belongsToMany association reference (122ms)
      ✓ should support a simple nested belongsTo -> belongsTo include (126ms)
      ✓ should support a simple sibling set of belongsTo include (115ms)
      ✓ should support a simple nested hasOne -> hasOne include (129ms)
      ✓ should support a simple nested hasMany -> belongsTo include (129ms)
      ✓ should support a simple nested belongsTo -> hasMany include (144ms)
      ✓ should support a simple nested hasMany to hasMany include (171ms)
    ✔ where relation in embed
      ✓ should support an include with multiple different association types (355ms)
      ✓ should support specifying attributes (85ms)
      ✓ should support Sequelize.literal and renaming of attributes in included model attributes (83ms)
      ✓ should support self associated hasMany (with through) include (97ms)
      ✓ should support including date fields, with the correct timeszone (116ms)
      ✓ should support include when retrieving associated objects (140ms)
    where
      ✓ should support Sequelize.and()
      ✓ should support Sequelize.or()
    findAndCountAll
      ✓ should include associations to findAndCountAll (88ms)
    association getter
      ✓ should support getting an include on a N:M association getter (155ms)
    right join
      ✓ should support getting an include with a right join (82ms)
      ✓ should support getting an include through with a right join (128ms)
    nested includes
      ✓ should not ripple grandchild required to top level find when required of child is set to false
    ✔ where complex with or + and (47ms)
      ✓ should support eager loading associations using the name of the relation (string)
      ✓ should not ripple grandchild required to top level find when required of child is not given (implicitly false)
      ✓ should ripple grandchild required to top level find when required of child is set to true as well

  [MYSQL] Include
    findAll
      ✓ should work on a nested set of relations with a where condition in between relations (241ms)
      ✓ should accept nested `where` and `limit` at the same time (183ms)
      ✓ should support an include with multiple different association types (473ms)
    ✔ where relations with operators (52ms)
      ✓ should support many levels of belongsTo (485ms)
      ✓ should support many levels of belongsTo (with a lower level having a where) (446ms)
      ✓ should support ordering with only belongsTo includes (242ms)
      ✓ should include attributes from through models (135ms)
    ✔ should not apply inner join if all conditions return undefined (38ms)
      ✓ should support a required belongsTo include (92ms)
      ✓ should be possible to extend the on clause with a where option on a belongsTo include (99ms)
      ✓ should be possible to extend the on clause with a where option on a belongsTo include (87ms)
      ✓ should be possible to define a belongsTo include as required with child hasMany not required (129ms)
      ✓ should be possible to define a belongsTo include as required with child hasMany with limit (141ms)
      ✓ should be possible to define a belongsTo include as required with child hasMany with limit and aliases (144ms)
      ✓ should be possible to define a belongsTo include as required with child hasMany which is not required with limit (143ms)
      ✓ should be possible to extend the on clause with a where option on a hasOne include (92ms)
      ✓ should be possible to extend the on clause with a where option on a hasMany include with a through model (127ms)
      ✓ should be possible to extend the on clause with a where option on nested includes (407ms)
      ✓ should be possible to use limit and a where with a belongsTo include (89ms)
    ✔ should apply inner join if true is applied (39ms)

  find options > where
    ✔ should skip undefined properties
    ✔ should skip null properties

  find options > opaque-types-over-primitives
    ✔ should work in select
    ✔ should work in where
    ✔ should work in order by

  indices > basic unique index test
    unique index
      ✓ should be possible use limit, attributes and a where on a belongsTo with additional hasMany includes (501ms)
      ✔ should work without errors

  indices > conditional index
    ✔ should correctly create conditional indices with WHERE condition
    ✔ should correctly drop conditional indices and revert drop

  indices > embeds index test
    embeddeds index
      ✔ should work without errors

  indices > fulltext index
    - should correctly create fulltext indices
    - with default parser
    - with ngram parser

  jsonb type
    ✔ should make correct schema with Postgres' jsonb type
    ✔ should persist jsonb correctly
    ✔ should persist jsonb string correctly
    ✔ should persist jsonb array correctly
    ✔ should create updates when changing object
    ✔ should not create updates when resorting object
    ✔ should not create new migrations when everything is equivalent

  json > defaults
    ✔ should insert default values properly

  ltree-postgres
    ✔ should create correct schema with Postgres' ltree type
    ✔ should persist ltree correctly
    ✔ should update ltree correctly
    ✔ should re-save ltree correctly
    ✔ should persist ltree correctly with trailing '.'
    ✔ should persist ltree correctly when containing spaces
    ✔ should be able to query ltree correctly

  metadata-builder > ColumnMetadata
    ✔ getValue
    ✔ getValueMap

  metadata builder > MetadataArgsUtils
    ✔ getInheritanceTree
    ✔ filterByTargetClasses

  migrations > generate command
    ✔ can recognize model changes
    ✔ does not generate when no model changes (208ms)

  migrations > show command
    ✔ can recognise pending migrations
    ✔ can recognise no pending migrations

  mongodb > array columns
    ✔ should insert / update array columns correctly
    ✔ should retrieve arrays from the column metadata

  mongodb > embedded columns
    ✔ should insert / update / remove entity with embedded correctly
    ✔ should store results in correct camelCase format
    ✔ should transform results to correct boolean value
    ✔ should transform entity with nested embedded columns correctly

  mongodb > embedded columns listeners
    ✔ should work listeners in entity embeddeds correctly
    ✔ should not work listeners in entity embeddeds if property is optional
    ✔ should work listeners in entity array embeddeds correctly

  mongodb > embeddeds indices
    ✔ should insert entity with embeddeds indices correctly

  mongodb > indices
    ✔ should insert entity with indices correctly

  mongodb > MongoRepository
    ✔ connection should return mongo repository when requested
    ✔ entity manager should return mongo repository when requested
    ✔ should be able to use entity cursor which will return instances of entity classes
    ✔ should be able to use entity cursor which will return instances of entity classes
    ✔ should be able to use findByIds with both ObjectId and strings
    ✔ should be able to save and update mongo entities
    ✔ should ignore non-column properties
    with DeletedDataColumn
      ✔ with $or query
      ✔ filter delete data
      findOne filtered data properly
        ✔ findOne()
        ✔ findOneBy()

  mongodb > object id columns
    ✔ should persist ObjectIdColumn property as _id to DB
    ✔ should map _id to ObjectIdColumn property and remove BD _id property
    ✔ should save and load properly if objectId property has name _id
    ✔ should not persist entity ObjectIdColumn property in DB on update by save

  mongodb > basic repository actions
    ✔ create should create instance of same entity
    ✔ create should be able to fill data from the given object
    ✔ merge should merge all given partial objects into given source entity
    ✔ merge should merge all given recursive partial objects into given source entity
    ✔ target should be valid
    ✔ should persist entity successfully and after persistence have generated object id
    ✔ hasId should return true if id really has an id
    ✔ unsupported methods should throw exception
    ✔ should return persisted objects using find* methods
    ✔ should sort entities in a query
    ✔ clear should remove all persisted entities
    ✔ remove should remove given entity
    ✔ clear should remove all persisted entities
    ✔ preload should pre-load given object

  mongodb > timestampable columns
    ✔ should persist timestampable columns

  multi-database > basic-functionality
    filepathToName()
      ✔ produces deterministic, unique, and valid table names for relative paths; leaves absolute paths unchanged (darwin)
      ✔ produces deterministic, unique, and valid table names for relative paths; leaves absolute paths unchanged (win32)
    multiple databases
      ✔ should correctly attach and create database files
      ✔ should prefix tableName when custom database used in Entity decorator
      ✔ should not affect tableName when using default main database
      ✔ should create foreign keys for relations within the same database

  multi-schema-and-database > custom-junction-database
    ✔ should correctly create tables when custom table schema used

  multi-schema-and-database > custom-junction-schema
    ✔ should correctly create tables when custom table schema used

  multi-schema-and-database > basic-functionality
    custom-table-schema
      ✔ should set the table database / schema
      ✔ should correctly get the table primary keys when custom table schema used
      ✔ should correctly create tables when custom table schema used
      ✔ should correctly create tables when custom table schema used in Entity decorator
      ✔ should correctly work with cross-schema queries
      ✔ should correctly work with QueryBuilder
    custom-table-schema-and-database
      ✔ should set the table database / schema
      ✔ should correctly get the table primary keys when custom table schema used
      ✔ should correctly create tables when custom database and custom schema used in Entity decorator
      ✔ should correctly work with cross-schema and cross-database queries in QueryBuilder
    custom-database
      ✓ should be possible to have the primary key in attributes (88ms)
      ✔ should correctly create tables when custom database used in Entity decorator

  LegacyOracleNamingStrategy > column shortening
    ✔ should truncate column names to the limit
    ✔ should change column names to hashes within the limit

  LegacyOracleNamingStrategy > create table using this naming strategy
    ✔ should create the table

  LegacyOracleNamingStrategy > create table using default naming strategy
    ✔ should not create the table and fail due to ORA-00972

  persistence > basic functionality
      ✓ should be possible to turn off the attributes for the through table (481ms)
    ✔ should save an entity
    ✔ should remove an entity
    ✔ should throw an error when not an object is passed to a save method
    ✔ should throw an error when not an object is passed to a remove method
    ✔ should throw an exception if object literal is given instead of constructed entity because it cannot determine what to save
      ✓ should be possible to select on columns inside a through table (507ms)
    ✔ should be able to save and remove entities of different types

  persistence > bulk-insert-remove-optimization
    ✔ should group multiple insert and remove queries

  persistence > cascades > example 1
    ✔ should insert everything by cascades properly

  persistence > cascades > example 2
      ✓ should be possible to select on columns inside a through table and a limit (531ms)
      ✓ should be possible not to include the main id in the attributes (103ms)
      ✓ should be possible to use limit and a where on a hasMany with additional includes (514ms)
      ✓ should be possible to use limit and a where on a hasMany with a through model with additional includes (505ms)
      ✓ should support including date fields, with the correct timeszone (114ms)
      ✓ should still pull the main record(s) when an included model is not required and has where restrictions without matches (121ms)
      ✓ should work with paranoid, a main record where, an include where, and a limit (93ms)
      ✓ should work on a nested set of required 1:1 relations (129ms)
      ✓ should work with an empty include.where (165ms)
      ✓ should be able to order on the main table and a required belongsTo relation with custom tablenames and limit  (93ms)
      ✓ should ignore include with attributes: [] (used for aggregates) (91ms)
    ✔ should insert everything by cascades properly

  persistence > cascades > remove
    - should remove everything by cascades properly

  persistence > cascades > remove
    - should soft-remove everything by cascades properly

  persistence > cascade operations with custom name
    cascade update
      ✓ should ignore include with attributes: [] and through: { attributes: [] } (used for aggregates) (132ms)
      ✓ should not add primary key when including and aggregating with raw: true (92ms)
      ✓ should return posts with nested include with inner join with a m:n association (222ms)
      ✓ should be able to generate a correct request with inner and outer join (173ms)
      ✔ should remove relation

  persistence > entity updation
    ✔ should update generated auto-increment id after saving
      ✓ should be able to generate a correct request for entity with 1:n and m:1 associations and limit (511ms)
    ✔ should update generated uuid after saving
    ✔ should update default values after saving
    ✔ should update special columns after saving
      ✓ should allow through model to be paranoid (148ms)

  [MYSQL] Include
    findAndCountAll
    ✔ should update even when multiple primary keys are used
      ✓ should be able to include two required models with a limit. Result rows should match limit. (125ms)
      ✓ should be able to include a required model. Result rows should match count (205ms)
      ✓ should count on a where and not use an uneeded include (95ms)
    ✔ should update even with embeddeds

  persistence > insert > update-relation-columns-after-insertion
      ✓ should return the correct count and rows when using a required belongsTo and a limit (100ms)
      ✓ should return the correct count and rows when using a required belongsTo with a where condition and a limit (94ms)
      ✓ should correctly filter, limit and sort when multiple includes and types of associations are present. (239ms)
      ✓ should properly work with sequelize.function (93ms)

  [MYSQL] Include
    findOne
      ✓ should include a non required model, with conditions and two includes N:M 1:M (202ms)
    ✔ should work perfectly

  persistence > many-to-many
      ✓ should work with a 1:M to M:1 relation with a where on the last include (132ms)
      ✓ should include a model with a where condition but no required (89ms)
      ✓ should include a model with a where clause when the PK field name and attribute name are different (87ms)
      ✓ should include a model with a through.where and required true clause when the PK field name and attribute name are different (129ms)
      ✓ should still pull the main record when an included model is not required and has where restrictions without matches (118ms)
      ✓ should support a nested include (with a where) (135ms)
    ✔ add exist element to exist object with empty many-to-many relation and save it and it should contain a new category
      ✓ should support a belongsTo with the targetKey option (99ms)
      ✓ should support many levels of belongsTo (with a lower level having a where) (404ms)
      ✓ should work with combinding a where and a scope (82ms)

  [MYSQL] Include
    LIMIT
    ✔ remove one element from many-to-many relation should remove from the database as well
      ✓ supports many-to-many association with where clause (555ms)
      ✓ supports 2 levels of required many-to-many associations (566ms)
    ✔ remove all elements from many-to-many relation should remove from the database as well
      ✓ supports 2 levels of required many-to-many associations with where clause (582ms)
    ✔ remove all elements (set to null) from many-to-many relation should remove from the database as well
      ✓ supports 2 levels of required many-to-many associations with through.where clause (596ms)
    ✔ remove all elements from many-to-many relation if parent entity is removed

  persistence > many-to-one bi-directional relation
      ✓ supports 3 levels of required many-to-many associations with where clause (632ms)
    ✔ should save a category with a post attached
      ✓ supports required many-to-many association (622ms)
    ✔ should save a category and a new post by cascades
      ✓ supports 2 required many-to-many association (646ms)
    ✔ should update exist post by cascades when category is saved
      ✓ supports required one-to-many association (636ms)
    ✔ should NOT remove exist post by cascades when category is saved without a post (post is set to undefined)
    ✔ should unset exist post when its set to null
      ✓ supports required one-to-many association with where clause (646ms)
    ✔ should set category's post to NULL when post is removed from the database (database ON DELETE)
      ✓ supports required one-to-many association with where clause (findOne) (650ms)
    ✔ should work when relation id is directly set into relation (without related object)

  persistence > many-to-one uni-directional relation
      ✓ supports 2 levels of required one-to-many associations (630ms)
    ✔ should save a category with a post attached
      ✓ supports required one-to-many association with nested required many-to-many association (673ms)
    ✔ should save a category and a new post by cascades
      ✓ supports required many-to-many association with nested required one-to-many association (656ms)
    ✔ should update exist post by cascades when category is saved
      ✓ supports required many-to-one association with nested many-to-many association with where clause (639ms)
    ✔ should NOT remove exist post by cascades when category is saved without a post (post is set to undefined)
      ✓ supports required many-to-one association with nested many-to-many association with through.where clause (617ms)
    ✔ should unset exist post when its set to null
      ✓ supports required many-to-one association with multiple nested associations with where clause (599ms)
    ✔ should set category's post to NULL when post is removed from the database (database ON DELETE)
    ✔ should work when relation id is directly set into relation (without related object)

  persistence > multi primary keys
    insert
      ✓ supports required many-to-one association with nested one-to-many association with where clause (589ms)

  [MYSQL] Paranoid
    ✓ paranoid with timestamps: false should be ignored / not crash (524ms)
      ✔ should insert entity when there are multi column primary keys

  persistence > multi primary keys on both sides
    insert
    ✓ test if non required is marked as false
    ✓ test if required is marked as true
      ✔ should insert entity when there are multi column primary keys

  persistence > null and default behaviour
    ✔ should insert value if it is set
    ✔ should insert default when post.title is undefined
    ✔ should insert NULL when post.title is null
    ✔ should update nothing when post.title is undefined
    ✔ should update to null when post.title is null

  persistence > one-to-many
    ✓ should not load paranoid, destroyed instances, with a non-paranoid parent (629ms)

  [MYSQL] Includes with schemas
    findAll
      ✓ should support an include with multiple different association types (436ms)
    ✔ should add exist element to exist object with empty one-to-many relation and save it
      ✓ should support many levels of belongsTo (476ms)
      ✓ should support ordering with only belongsTo includes (181ms)
    ✔ should add exist element to new object with empty one-to-many relation and save it
      ✓ should include attributes from through models (131ms)
      ✓ should support a required belongsTo include (84ms)
      ✓ should be possible to extend the on clause with a where option on a belongsTo include (80ms)
      ✓ should be possible to extend the on clause with a where option on a belongsTo include (79ms)
      ✓ should be possible to define a belongsTo include as required with child hasMany with limit (128ms)
      ✓ should be possible to define a belongsTo include as required with child hasMany with limit and aliases (129ms)
      ✓ should be possible to define a belongsTo include as required with child hasMany which is not required with limit (125ms)
      ✓ should be possible to extend the on clause with a where option on a hasOne include (87ms)
    ✔ should remove exist element from one-to-many relation and save it
      ✓ should be possible to extend the on clause with a where option on a hasMany include with a through model (177ms)
      ✓ should be possible to extend the on clause with a where option on nested includes (394ms)
    ✔ should remove all elements from one-to-many relation and save it
      ✓ should be possible to use limit and a where with a belongsTo include (87ms)
      ✓ should be possible use limit, attributes and a where on a belongsTo with additional hasMany includes (474ms)
    ✔ set relation to null (elements exist there) from one-to-many relation and save it

  persistence > one-to-one
    set the relation with proper item
      ✔ should have an access token
    doesn't allow the same relation to be used twice
      ✔ should reject the saving attempt (56ms)

  persistence > orphanage > delete
    when a Post is removed from a Category
      ✓ should be possible to use limit and a where on a hasMany with additional includes (468ms)
      ✓ should be possible to use limit and a where on a hasMany with a through model with additional includes (478ms)
      ✔ should retain a Post on the Category
      ✓ should support including date fields, with the correct timezone (107ms)
    findOne
      ✓ should work with schemas (80ms)

  [MYSQL] Include
    separate
      ✓ should run a hasMany association in a separate query (97ms)
      ✓ should work even if the id was not included (92ms)
      ✓ should work even if include does not specify foreign key attribute with custom sourceKey (88ms)
      ✓ should not break a nested include with null values (119ms)
      ✔ should delete the orphaned Post from the database
      ✓ should run a hasMany association with limit in a separate query (166ms)
      ✓ should run a nested (from a non-separate include) hasMany association in a separate query (127ms)
      ✓ should work having a separate include between a parent and child include (178ms)
      ✓ should run two nested hasMany association in a separate queries (127ms)
      ✓ should work with two schema models in a hasMany association (178ms)
      ✓ should work with required non-separate parent and required child (126ms)

  [MYSQL] Instance
    Escaping
      ✓ is done properly for special characters
    isNewRecord
      ✓ returns true for non-saved objects
      ✔ should retain foreign keys on remaining Posts

  persistence > orphanage > disable
    when a User is updated without all settings being loaded...
      ✓ returns false for saved objects
      ✓ returns false for created objects
      ✓ returns false for upserted objects
      ✓ returns false for objects found by find method
      ✓ returns false for objects found by findAll method
    default values
      uuid
        ✓ should store a string in uuidv1 and uuidv4
        ✓ should store a string of length 36 in uuidv1 and uuidv4
        ✓ should store a valid uuid in uuidv1 and uuidv4 that conforms to the UUID v1 and v4 specifications
        ✓ should store a valid uuid if the multiple primary key fields used
      current date
        ✓ should store a date in touchedAt
        ✓ should store the current date in touchedAt
      allowNull date
        ✓ should be just "null" and not Date with Invalid Date
        ✓ should be the same valid date when saving the date
      super user boolean
        ✓ should default to false
        ✓ should override default when given truthy boolean
        ✓ should override default when given truthy boolean-string ("true")
        ✓ should override default when given truthy boolean-int (1)
        ✓ should throw error when given value of incorrect type
    complete
      ✓ gets triggered if an error occurs
      ✓ gets triggered if everything was ok
    findAll
      ✓ sql should have paranoid condition
      ✔ should not delete setting with orphanedRowAction=disabed
      ✓ sequelize.and as where should include paranoid condition
      ✓ sequelize.or as where should include paranoid condition
      ✓ escapes a single single quotes properly in where clauses
      ✓ escapes two single quotes properly in where clauses
      ✓ returns the timestamps if no attributes have been specified
      ✓ does not return the timestamps if the username attribute has been specified
      ✔ should not orphane any Settings

  persistence > partial persist
      ✓ creates the deletedAt property, when defining paranoid as true
    ✔ should persist partial entities without data loss

  persistence > persistence options > chunks
    ✔ should save objects in chunks

  persistence > persistence options > listeners
      ✓ destroys a record with a primary key of something other than id
    ✔ save listeners should work by default
    ✔ save listeners should be disabled if save option is specified
      ✓ sets deletedAt property to a specific date when deleting an instance
      ✓ keeps the deletedAt-attribute with value null, when running update
    ✔ remove listeners should work by default
      ✓ keeps the deletedAt-attribute with value null, when updating associations
    ✔ remove listeners should be disabled if remove option is specified
      ✓ can reuse query option objects
    findOne
      ✓ can reuse query option objects
    ✔ soft-remove listeners should work by default
    ✔ soft-remove listeners should be disabled if remove option is specified

  persistence > persistence options > transaction
      ✓ returns null for null, undefined, and unset boolean values
    equals
      ✓ can compare records with Date field
    ✔ should disable transaction when option is specified
    ✔ should disable transaction when the drivers transactionSupport setting equals `none`

  persistence > order of persistence execution operations
    should throw exception when non-resolvable circular relations found
      ✔ should throw CircularRelationsError
    should persist all entities in correct order
      - 

  persistence > remove-topological-order
      ✓ does not compare the existence of associations (89ms)
    values
      ✓ returns all values
    isSoftDeleted
      ✓ should return false when model is just created
      ✓ returns false if user is not soft deleted
      ✓ returns true if user is soft deleted
      ✓ works with custom `deletedAt` field name
    restore
      ✓ returns an error if the model is not paranoid
      ✓ restores a previously deleted model (42ms)
      ✓ supports custom deletedAt field (43ms)
      ✓ supports custom deletedAt field name (38ms)
      ✓ supports custom deletedAt field and database column (43ms)
      ✓ supports custom default value

  [MYSQL] InstanceValidator
    ✓ correctly validates using custom validation methods
    ✓ supports promises with custom validation methods
    ✔ should remove depend properties in a proper order

  query builder > brackets
    ✔ should put parentheses in the SQL
    ✔ should put brackets correctly into WHERE expression

  query builder > cache
    ✓ skips other validations if allowNull is true and the value is null
    ✓ validates a model with custom model-wide validation methods
    ✓ validates model with a validator whose arg is an Array successfully twice in a row
    ✓ validates enums
    ✓ skips validations for the given fields
    ✓ skips validations for fields with value that is SequelizeMethod
    ✓ raises an error if saving a different value into an immutable field
    ✓ allows setting an immutable field if the record is unsaved
    ✓ raises an error for array on a STRING
    ✓ raises an error for array on a STRING(20)
    ✓ raises an error for array on a TEXT
    ✓ raises an error for {} on a STRING
    ✓ raises an error for {} on a STRING(20)
    ✓ raises an error for {} on a TEXT
    ✓ does not raise an error for null on a STRING (where null is allowed)
    ✓ validates VIRTUAL fields
    ✓ allows me to add custom validation functions to validator.js
    #update
      ✓ should allow us to update specific columns without tripping the validations (39ms)
      ✓ should be able to emit an error upon updating when a validation has failed from an instance
      ✓ should be able to emit an error upon updating when a validation has failed from the factory
      ✓ should enforce a unique constraint
      ✓ should allow a custom unique constraint error message
      ✓ should handle multiple unique messages correctly
    #create
      generic
        ✓ correctly throws an error using create method 
    ✔ should cache results properly (1022ms)
        ✓ correctly validates using create method 
      explicitly validating primary/auto incremented columns
        ✓ should emit an error when we try to enter in a string for the id key without validation arguments
        ✓ should emit an error when we try to enter in a string for an auto increment key (not named id)
        primaryKey with the name as id with arguments for it's validatio
          ✓ should emit an error when we try to enter in a string for the id key with validation arguments
          ✓ should emit an error when we try to enter in a string for an auto increment key through .build().validate()
          ✓ should emit an error when we try to .save()
      pass all paths when validating
        ✓ produce 3 errors
      not null schema validation
        ✓ correctly throws an error using create method 
        ✓ correctly throws an error using create method with default generated messages

  [MYSQL] Instance
    decrement
      ✓ supports transactions (81ms)
      ✓ with array
      ✓ with single field
      ✓ with single field and no value
      ✓ should still work right with other concurrent updates
      ✓ should still work right with other concurrent increments
    ✔ should cache results with pagination enabled properly (1022ms)
      ✓ with key value pair
      ✓ with negative value
      ✓ with timestamps set to true
      ✓ with timestamps set to true and options.silent set to true

  [MYSQL] Instance
    destroy
      ✓ supports transactions
      ✓ does not set the deletedAt date in subsequent destroys if dao is paranoid (39ms)
      ✓ does not update deletedAt with custom default in subsequent destroys
      ✓ deletes a record from the database if dao is not paranoid (160ms)
      ✓ allows updating soft deleted instance (42ms)
      ✓ supports custom deletedAt field
      ✓ supports custom deletedAt database column
      ✓ supports custom deletedAt field and database column
      ✓ persists other model changes when soft deleting (38ms)
      ✓ allows sql logging of delete statements
      ✓ allows sql logging of update statements
      ✓ should not call save hooks when soft deleting
      ✓ delete a record of multiple primary keys table (39ms)

  [MYSQL] Instance
    increment
      ✓ supports transactions (80ms)
      ✓ supports where conditions
      ✓ with array
      ✓ with single field
      ✓ with single field and no value
      ✓ should still work right with other concurrent updates
    ✔ should cache results with custom id and duration supplied (2022ms)
      ✓ should still work right with other concurrent increments
      ✓ with key value pair
      ✓ single value should work when field name is different from database column name
      ✓ array should work when field name is different from database column name
      ✓ key value should work when field name is different from database column name
      ✓ with timestamps set to true
      ✓ with timestamps set to true and options.silent set to true

  [MYSQL] Instance
    reload
      ✓ supports transactions (79ms)
      ✓ should return a reference to the same DAO instead of creating a new one
    ✔ should cache results with custom id and duration supplied (1021ms)

  query builder > comment
    ✔ should scrub end comment pattern from string
    ✔ should not allow an empty comment
      ✓ should use default internal where
      ✓ should update the values on all references to the DAO
      ✓ should support updating a subset of attributes
    ✔ should allow a comment with just whitespaces
    ✔ should allow a multi-line comment
    ✔ should include comment in select
      ✓ should update read only attributes as well (updatedAt)
      ✓ should update the associations as well (85ms)
    ✔ should include comment in update
    ✔ should include comment in insert
    ✔ should include comment in delete

  query builder > composite primary
    ✔ should find entity by another entity with a composite key

  query builder > count
      ✓ should update internal options of the instance (78ms)
      ✓ should return an error when reload fails
    ✔ Count query should of empty table should be 0
    ✔ Count query should count database values
      ✓ should set an association to null after deletion, 1-1 (162ms)
    ✔ Count query should handle ambiguous values
      ✓ should set an association to empty after all deletion, 1-N (163ms)
    ✔ counting joined query should count database values
    ✔ counting joined queries should handle ambiguous values

  query builder > cte > materialized
      ✓ should update the associations after one element deleted (163ms)
    ✔ should allow MATERIALIZED hint
    ✔ should allow NOT MATERIALIZED hint
    ✔ should omit hint if materialized option is not set

  query builder > cte > recursive
      ✓ should inject default scope when reloading (83ms)

  [MYSQL] Instance
    save
    ✔ should work with simple recursive query

  query builder > cte > simple
      ✓ supports transactions (84ms)
      ✓ only updates fields in passed array
    ✔ show allow select from CTE
    ✔ should allow join with CTE
      ✓ should work on a model with an attribute named length (38ms)
      ✓ only validates fields in passed array
      ✓ stores an entry in the database
    ✔ should allow to use INSERT with RETURNING clause in CTE
    ✔ should allow string for CTE

  query builder > delete
    ✔ should perform deletion correctly
      ✓ handles an entry with primaryKey of zero
      ✓ updates the timestamps
    ✔ should be able to delete entities by embed criteria
      ✓ does not update timestamps when passing silent=true
      ✓ does not update timestamps when passing silent=true in a bulk update
    ✔ should return correct delete result
      ✓ updates with function and column value
      ✓ updates with function that contains escaped dollar symbol
      ✓ updates with function that contains multiple escaped dollar symbols
    ✔ should throw error when unknown property in where criteria

  query builder > distinct on
    ✔ should perform distinct on category authors
    ✔ should perform distinct on post authors and moderators combination
    ✔ should perform distinct on post and category authors

  query builder > enabling transaction
    ✔ should execute query in a transaction

  query builder > entity updation
      ✓ should fail a validation upon creating
      ✓ should fail a validation upon creating with hooks false
      ✓ should fail a validation upon building
    ✔ should update entity model after insertion if updateEntity is set to true
    ✔ should not update entity model after insertion if updateEntity is set to false
    ✔ should not override already set properties
      ✓ should fail a validation when updating
      ✓ takes zero into account
      ✓ saves a record with no primary key (41ms)
    ✔ should update entity model after save
    ✔ should update special entity properties after entity updation if updateEntity is set to true
      hooks
        ✓ should update attributes added in hooks when default fields are used
    ✔ should not update special entity properties after entity updation if updateEntity is set to false

  query builder > exist
    ✔ Exists query of empty table should be false
        ✓ should update attributes changed in hooks when default fields are used
        ✓ should validate attributes added in hooks when default fields are used (40ms)
    ✔ Exists query of non empty table should be true

  query builder > insert
    ✔ should perform insertion correctly
        ✓ should validate attributes changed in hooks when default fields are used (38ms)
      when nothing changed
        ✓ does not update timestamps
        ✓ should not throw ER_EMPTY_QUERY if changed only virtual fields
      without timestamps option
    ✔ should perform bulk insertion correctly
    ✔ should be able to use sql functions
        ✓ doesn't update the updatedAt column
      with custom timestamp options
        ✓ updates the createdAt column if updatedAt is disabled
        ✓ updates the updatedAt column if createdAt is disabled
    ✔ should be able to insert entities with different properties set even inside embeds

  query builder > insertion > on conflict
    ✔ should perform insertion correctly using onConflict
    ✔ should support alias in insert
    ✔ should perform insertion correctly using orIgnore
    ✔ should perform insertion correctly using orUpdate
    ✔ should perform insertion on partial index using orUpdate
    ✔ should perform insertion using partial index and skipping update on no change
    ✔ should throw error if using indexPredicate amd an unsupported driver

  query builder > joins
    leftJoinAndSelect
        ✓ works with `allowNull: false` on createdAt and updatedAt columns
      eagerly loaded objects
        ✓ saves one object that has a collection of eagerly loaded objects
        ✓ saves many objects that each a have collection of eagerly loaded objects
        ✓ saves many objects that each has one eagerly loaded object (to which they belong)

  [MYSQL] Instance
    toJSON
      ✓ doesn't return instance that isn't defined
      ✓ doesn't return instances that aren't defined
      ✓ includes the eagerly loaded associations
      build
        ✓ returns an object containing all values
        ✓ returns a response that can be stringified
        ✓ returns a response that can be stringified and then parsed
      create
        ✓ returns an object containing all values
        ✓ returns a response that can be stringified
      ✔ should load data for all relation types (329ms)
        ✓ returns a response that can be stringified and then parsed
      find
        ✓ returns an object containing all values
        ✓ returns a response that can be stringified
        ✓ returns a response that can be stringified and then parsed

  [MYSQL] Instance
    update
      ✓ supports transactions (87ms)
      ✓ should update fields that are not specified on create (38ms)
      ✓ should succeed in updating when values are unchanged (without timestamps)
      ✓ should update timestamps with milliseconds
      ✓ should only save passed attributes
      ✓ should save attributes affected by setters
      ✓ should not set attributes that are not specified by fields
      ✓ updates attributes in the database
      ✓ ignores unknown attributes
      ✓ ignores undefined attributes (79ms)
      ✓ doesn't update primary keys or timestamps
      ✓ stores and restores null values (39ms)
      ✓ should support logging
      hooks
      ✔ should load data when additional condition used
        ✓ should update attributes added in hooks when default fields are used (40ms)
        ✓ should update attributes changed in hooks when default fields are used
        ✓ should validate attributes added in hooks when default fields are used
        ✓ should validate attributes changed in hooks when default fields are used

  [MYSQL] DAO
    Values
      set
        ✓ doesn't overwrite generated primary keys
        ✓ doesn't overwrite defined primary keys
        ✓ doesn't set timestamps
        ✓ doesn't set underscored timestamps
        ✓ doesn't set value if not a dynamic setter or a model attribute
        ✓ allows use of sequelize.fn and sequelize.col in date and bool fields
        includes
          ✓ should support basic includes
          ✓ should support basic includes (with raw: true)
      get
        ✓ should use custom attribute getters in get(key)
        ✓ should custom virtual getters in get(key)
        ✓ should use custom getters in toJSON
        ✓ should work with save
        ✓ can pass parameters to getters
        plain
          ✓ should return plain values when true
        clone
          ✓ should copy the values
      changed
        ✓ should return false if object was built from database (41ms)
        ✓ should return true if previous value is different
        ✓ should return false immediately after saving
        ✓ should be available to a afterUpdate hook (48ms)
      previous
        ✓ should return an object with the previous values
        ✓ should return the previous value

  model
    json
      ✓ should tell me that a column is json
      ✓ should use a placeholder for json with insert
      ✓ should insert json using a custom field name
      ✓ should update json using a custom field name
      ✓ should be able retrieve json value as object
      ✓ should be able to retrieve element of array by index
      ✔ should load data when join tables does not have direct relation
    innerJoinAndSelect
      ✓ should be able to retrieve root level value of an object by key
      ✓ should be able to retrieve nested value of an object by path
      ✓ should be able to retrieve a row based on the values of the json document
      ✓ should be able to query using the nested query language
      ✓ should be able to query using dot notation
      ✓ should be able to query using dot notation with uppercase name
      ✓ should be able to query array using property accessor
      ✓ should be able to store strings
      ✓ should be able to store values that require JSON escaping
      ✔ should load only exist data for all relation types
      ✓ should be able to findOrCreate with values that require JSON escaping
      ✓ should be able retrieve json value with nested include

  [MYSQL] Model
      ✔ should load data when additional condition used
    ✓ supports multiple async transactions (2058ms)
    ✓ should be possible to use a key named UUID as foreign key (115ms)
    constructor
      ✓ uses the passed dao name as tablename if freezeTableName
      ✓ uses the pluralized dao name as tablename unless freezeTableName
      ✓ uses checks to make sure dao factory is not leaking on multiple define
      ✓ allows us to predefine the ID column with our own specs
      ✓ throws an error if 2 autoIncrements are passed
      ✓ throws an error if a custom model-wide validation is not a function
      ✓ throws an error if a custom model-wide validation has the same name as a field
      ✓ should allow me to set a default value for createdAt and updatedAt
      ✓ should allow me to set a function as default value
      ✓ should throw `TypeError` when value for updatedAt, createdAt, or deletedAt is neither string nor boolean
      ✓ should allow me to use `true` as a value for updatedAt, createdAt, and deletedAt fields
      ✓ should allow me to override updatedAt, createdAt, and deletedAt fields
      ✓ should allow me to disable some of the timestamp fields
      ✓ returns proper defaultValues after save when setter is set
      ✓ should work with both paranoid and underscored being true
      ✓ allows multiple column unique keys to be defined
      ✓ allows unique on column with field aliases
      ✔ should not return any result when related data does not exist
    leftJoinAndMap
      ✓ allows us to customize the error message for unique constraint
      ✓ allows us to map the customized error message with unique constraint name (1397ms)
      - should allow the user to specify indexes in options
      descending indices (MySQL 8 specific)
      ✔ should load and map selected data when entity used as join argument
        ✓ complains about missing support for descending indexes (1389ms)
        ✓ works fine with InnoDB (1399ms)
    build
      ✓ doesn't create database entries
      ✓ fills the objects with default values
      ✓ fills the objects with default values
      ✓ attaches getter and setter methods from attribute definition
      ✓ attaches getter and setter methods from options
      ✔ should load and map selected data when table name used as join argument
      ✓ attaches getter and setter methods from options only if not defined in attribute
      include
        ✓ should support basic includes
        ✓ should support includes with aliases
    findOne
      ✓ supports the transaction option in the first parameter (84ms)
      ✓ should not fail if model is paranoid and where is an empty array (84ms)
      ✓ should work if model is paranoid and only operator in where clause is a Symbol (#8406) (88ms)
    findOrBuild
      ✓ supports transactions (87ms)
      returns an instance if it already exists
        ✓ with a single find field
        ✓ with multiple find fields
        ✓ builds a new instance with default value.
    save
      ✓ should map the correct fields when saving instance (#10589) (86ms)
    update
      ✓ throws an error if no where clause is given (78ms)
      ✓ should map the correct fields when updating instance (#10589) (85ms)
      ✓ supports transactions (86ms)
      ✓ updates the attributes that we select only without updating createdAt (38ms)
      ✓ allows sql logging of updated statements (82ms)
      ✓ updates only values that match filter
      ✓ throws an error if where has a key with undefined value
      ✓ updates only values that match the allowed fields
      ✓ updates with casting
      ✔ should load and map selected data when query builder used as join argument
      ✓ updates with function and column value
      ✓ does not update virtual attributes
      ✓ doesn't update attributes that are altered by virtual setters when option is enabled (39ms)
      ✓ updates attributes that are altered by virtual setters (40ms)
      ✓ should properly set data when individualHooks are true
      ✓ sets updatedAt to the current timestamp
      ✓ returns the number of affected rows
      ✓ does not update soft deleted records when model is paranoid (137ms)
      ✓ updates soft deleted records when paranoid is overridden (124ms)
      ✓ calls update hook for soft deleted objects (95ms)
      ✓ supports limit clause
    destroy
      ✓ `truncate` method should clear the table (118ms)
      ✓ `truncate` option should clear the table (123ms)
      ✓ `truncate` option returns a number (119ms)
      ✔ should load and map selected data when data will given from same entity but with different conditions
      ✓ throws an error if no where clause is given (86ms)
      ✓ deletes all instances when given an empty where object (91ms)
      ✓ throws an error if where has a key with undefined value (84ms)
      ✓ supports transactions (83ms)
      ✓ deletes values that match filter
      ✓ works without a primary key
      ✓ supports .field (45ms)
      ✓ sets deletedAt to the current timestamp if paranoid is true (43ms)
      ✓ does not set deletedAt for previously destroyed instances if paranoid is true (47ms)
      ✓ should include deleted associated records if include has paranoid marked as false (150ms)
      ✓ should delete a paranoid record if I set force to true (51ms)
      ✓ returns the number of affected rows
      ✓ supports table schema/prefix (92ms)
      ✓ should work if model is paranoid and only operator in where clause is a Symbol (87ms)
      can't find records marked as deleted with paranoid being true
        ✓ with the DAOFactory (42ms)
      can find paranoid records if paranoid is marked as false in query
        ✓ with the DAOFactory (42ms)
    restore
      ✓ rejects with an error if the model is not paranoid
      ✓ restores a previously deleted model (42ms)
    equals
      ✓ correctly determines equality of objects
      ✓ correctly determines equality with multiple primary keys
    equalsOneOf
      ✓ determines equality if one is matching
      ✓ doesn't determine equality if none is matching
    count
      ✓ supports transactions (97ms)
      ✓ counts all created objects
      ✓ returns multiple rows when using group
      ✓ allows sql logging
      ✓ filters object
      ✓ supports distinct option (92ms)
      ✔ should load and map selected data when data will given from same property but with different conditions (38ms)
    innerJoinAndMap
      aggregate
Executing (default): SELECT `id` AS `id2`, count(`id`) AS `count` FROM `Users` AS `User` GROUP BY `id2`;
(node:776) [SEQUELIZE0002] DeprecationWarning: The logging-option should be either a function or false. Default: console.log
        ✓ allows grouping by aliased attribute
      options sent to aggregate
        ✓ modifies option "limit" by setting it to null
        ✓ modifies option "offset" by setting it to null
        ✓ modifies option "order" by setting it to null
    min
      ✓ supports transactions (93ms)
      ✓ returns the correct value
      ✓ allows sql logging
      ✓ should allow decimals
      ✓ should allow strings
      ✓ should allow dates
      ✓ should work with fields named as an SQL reserved keyword
      ✔ should load and map selected data when entity used as join argument
    max
      ✓ supports transactions (95ms)
      ✓ returns the correct value
      ✓ allows sql logging
      ✓ should allow decimals
      ✓ should allow strings
      ✓ should allow dates
      ✓ should work with fields named as an SQL reserved keyword
    sum
      ✓ should work in the simplest case
      ✔ should load and map selected data when table name used as join argument
      ✓ should work with fields named as an SQL reserved keyword
      ✓ should allow decimals in sum
      ✓ should accept a where clause
      ✓ should accept a where clause with custom fields
      ✓ allows sql logging
    schematic support
      ✓ should be able to drop with schemas
      ✔ should load and map selected data when query builder used as join argument
      ✓ should be able to list schemas
      ✓ should take schemaDelimiter into account if applicable (74ms)
      ✓ should describeTable using the default schema settings (68ms)
      ✓ should be able to reference a table with a schema set (75ms)
      ✓ should be able to create and update records under any valid schematic (41ms)
    references
      ✓ uses an existing dao factory and references the author table (44ms)
      ✓ uses a table name as a string and references the author table (42ms)
      - emits an error event as the referenced table name is invalid
      ✓ works with comments (247ms)
    blob
      buffers
        ✓ should be able to take a buffer as parameter to a BLOB field
        ✓ should return a buffer when fetching a blob
        ✓ should work when the database returns null
      strings
        ✓ should be able to take a string as parameter to a BLOB field
      ✔ should load and map selected data when data will given from same entity but with different conditions
        ✓ should return a buffer when fetching a BLOB, even when the BLOB was inserted as a string
    paranoid is true and where is an array
      ✓ should not fail when array contains Sequelize.or / and
      ✓ should fail when array contains strings
      ✓ should not fail with an include
      ✓ should not overwrite a specified deletedAt by setting paranoid: false
      ✔ should load and map selected data when data will given from same property but with different conditions (38ms)
      ✓ should not overwrite a specified deletedAt (complex query) by setting paranoid: false
    Unique
      ✓ should set unique when unique is true
      ✓ should not set unique when unique is false
      ✓ should not set unique when unique is unset
    bulkCreate
      ✓ errors - should return array of errors if validate and individualHooks are true (90ms)
      ✓ should not use setter when renaming fields in dataValues (92ms)

  [MYSQL] Model
    attributes
      set
        ✓ should only be called once when used on a join model called with an association getter (129ms)
        ✓ allows for an attribute to be called "toString" (43ms)
        ✓ allows for an attribute to be called "toString" with associations (97ms)
      quote
        ✓ allows for an attribute with dots

  [MYSQL] Model
    attributes
      field
        ✓ increment should work (40ms)
      ✔ should not return any result when related data does not exist

  query builder > locking
        ✓ decrement should work (41ms)
        ✓ sum should work
        ✓ should create, fetch and update with alternative field names from a simple model
        ✓ should bulk update (406ms)
        ✓ should not contain the field properties after create
        ✓ should make the aliased auto incremented primary key available after create
        ✓ should work with where on includes for find
        ✓ should work with where on includes for findAll
    ✔ should not attach pessimistic read lock statement on query if locking is not used
        ✓ should work with increment
        ✓ should work with a simple where
        ✓ should work with a where or
        ✓ should work with bulkCreate and findAll
        ✓ should support renaming of sequelize method fields (448ms)
    ✔ should throw error if pessimistic lock used without transaction
        ✓ should sync foreign keys with custom field names (409ms)
        ✓ should find the value of an attribute with a custom field name
        ✓ field names that are the same as property names should create, update, and read correctly
        ✓ should work with a belongsTo association getter
        ✓ should work with paranoid instance.destroy() (92ms)
        ✓ should work with paranoid Model.destroy() (88ms)
        ✓ should work with `belongsToMany` association `count`
        ✓ should work with `hasMany` association `count`
        primaryKey
          ✓ should support instance.destroy()
    1) should not throw error if pessimistic lock used with transaction


  624 passing (6m)
  26 pending
  1 failing

  1) query builder > locking
       should not throw error if pessimistic lock used with transaction:
     AssertionError: expected promise not to be rejected but it was rejected with 'QueryFailedError: ER_NOT_SUPPORTED_YE…'
  



typeorm-0.3.17 end
=========== ERROR EXIT [1]: FULL tidb.log BEGIN ============
[2024/05/17 15:34:06.912 +00:00] [INFO] [printer.go:47] ["Welcome to TiDB."] ["Release Version"=v8.2.0-alpha-191-gf5ac93e448] [Edition=Community] ["Git Commit Hash"=f5ac93e448a03665274272929b512ce66f05d67b] ["Git Branch"=HEAD] ["UTC Build Time"="2024-05-17 15:27:46"] [GoVersion=go1.21.0] ["Race Enabled"=false] ["Check Table Before Drop"=false]
[2024/05/17 15:34:06.912 +00:00] [INFO] [cgmon.go:130] ["set the maxprocs"] [quota=6]
[2024/05/17 15:34:06.913 +00:00] [INFO] [printer.go:52] ["loaded config"] [config="{\"host\":\"0.0.0.0\",\"advertise-address\":\"10.233.109.250\",\"port\":4001,\"cors\":\"\",\"store\":\"tikv\",\"path\":\"127.0.0.1:2379\",\"socket\":\"\",\"lease\":\"0\",\"split-table\":false,\"token-limit\":1000,\"temp-dir\":\"/tmp/tidb\",\"tmp-storage-path\":\"/tmp/0_tidb/MC4wLjAuMDo0MDAxLzAuMC4wLjA6OTA4MQ==/tmp-storage\",\"tmp-storage-quota\":-1,\"server-version\":\"\",\"version-comment\":\"\",\"tidb-edition\":\"\",\"tidb-release-version\":\"\",\"keyspace-name\":\"\",\"log\":{\"level\":\"error\",\"format\":\"text\",\"disable-timestamp\":null,\"enable-timestamp\":null,\"disable-error-stack\":null,\"enable-error-stack\":null,\"file\":{\"filename\":\"\",\"max-size\":300,\"max-days\":0,\"max-backups\":0,\"compression\":\"\"},\"slow-query-file\":\"tidb-slow.log\",\"expensive-threshold\":10000,\"general-log-file\":\"\",\"query-log-max-len\":4096,\"enable-slow-log\":true,\"slow-threshold\":300,\"record-plan-in-slow-log\":1,\"timeout\":0},\"instance\":{\"tidb_general_log\":false,\"tidb_pprof_sql_cpu\":false,\"ddl_slow_threshold\":300,\"tidb_expensive_query_time_threshold\":60,\"tidb_expensive_txn_time_threshold\":600,\"tidb_stmt_summary_enable_persistent\":false,\"tidb_stmt_summary_filename\":\"tidb-statements.log\",\"tidb_stmt_summary_file_max_days\":3,\"tidb_stmt_summary_file_max_size\":64,\"tidb_stmt_summary_file_max_backups\":0,\"tidb_enable_slow_log\":true,\"tidb_slow_log_threshold\":300,\"tidb_record_plan_in_slow_log\":1,\"tidb_check_mb4_value_in_utf8\":true,\"tidb_force_priority\":\"NO_PRIORITY\",\"tidb_memory_usage_alarm_ratio\":0.8,\"tidb_enable_collect_execution_info\":true,\"plugin_dir\":\"/data/deploy/plugin\",\"plugin_load\":\"\",\"max_connections\":0,\"tidb_enable_ddl\":true,\"tidb_rc_read_check_ts\":false,\"tidb_service_scope\":\"\"},\"security\":{\"skip-grant-table\":false,\"ssl-ca\":\"\",\"ssl-cert\":\"\",\"ssl-key\":\"\",\"cluster-ssl-ca\":\"\",\"cluster-ssl-cert\":\"\",\"cluster-ssl-key\":\"\",\"cluster-verify-cn\":null,\"session-token-signing-cert\":\"\",\"session-token-signing-key\":\"\",\"spilled-file-encryption-method\":\"plaintext\",\"enable-sem\":false,\"auto-tls\":false,\"tls-version\":\"\",\"rsa-key-size\":4096,\"secure-bootstrap\":false,\"auth-token-jwks\":\"\",\"auth-token-refresh-interval\":\"1h0m0s\",\"disconnect-on-expired-password\":true},\"status\":{\"status-host\":\"0.0.0.0\",\"metrics-addr\":\"\",\"status-port\":9081,\"metrics-interval\":15,\"report-status\":true,\"record-db-qps\":false,\"record-db-label\":false,\"grpc-keepalive-time\":10,\"grpc-keepalive-timeout\":3,\"grpc-concurrent-streams\":1024,\"grpc-initial-window-size\":2097152,\"grpc-max-send-msg-size\":2147483647},\"performance\":{\"max-procs\":0,\"max-memory\":0,\"server-memory-quota\":0,\"stats-lease\":\"0\",\"stmt-count-limit\":5000,\"pseudo-estimate-ratio\":0.8,\"bind-info-lease\":\"3s\",\"txn-entry-size-limit\":6291456,\"txn-total-size-limit\":104857600,\"tcp-keep-alive\":true,\"tcp-no-delay\":true,\"cross-join\":true,\"distinct-agg-push-down\":false,\"projection-push-down\":false,\"max-txn-ttl\":3600000,\"index-usage-sync-lease\":\"\",\"plan-replayer-gc-lease\":\"10m\",\"gogc\":100,\"enforce-mpp\":false,\"stats-load-concurrency\":0,\"stats-load-queue-size\":1000,\"analyze-partition-concurrency-quota\":16,\"plan-replayer-dump-worker-concurrency\":1,\"enable-stats-cache-mem-quota\":true,\"committer-concurrency\":128,\"run-auto-analyze\":true,\"force-priority\":\"NO_PRIORITY\",\"memory-usage-alarm-ratio\":0.8,\"enable-load-fmsketch\":false,\"lite-init-stats\":true,\"force-init-stats\":true,\"concurrently-init-stats\":true},\"prepared-plan-cache\":{\"enabled\":true,\"capacity\":100,\"memory-guard-ratio\":0.1},\"opentracing\":{\"enable\":false,\"rpc-metrics\":false,\"sampler\":{\"type\":\"const\",\"param\":1,\"sampling-server-url\":\"\",\"max-operations\":0,\"sampling-refresh-interval\":0},\"reporter\":{\"queue-size\":0,\"buffer-flush-interval\":0,\"log-spans\":false,\"local-agent-host-port\":\"\"}},\"proxy-protocol\":{\"networks\":\"\",\"header-timeout\":5,\"fallbackable\":false},\"pd-client\":{\"pd-server-timeout\":3},\"tikv-client\":{\"grpc-connection-count\":4,\"grpc-keepalive-time\":10,\"grpc-keepalive-timeout\":3,\"grpc-compression-type\":\"none\",\"grpc-shared-buffer-pool\":false,\"grpc-initial-window-size\":134217728,\"grpc-initial-conn-window-size\":134217728,\"commit-timeout\":\"41s\",\"async-commit\":{\"keys-limit\":256,\"total-key-size-limit\":4096,\"safe-window\":2000000000,\"allowed-clock-drift\":500000000},\"max-batch-size\":128,\"overload-threshold\":200,\"max-batch-wait-time\":0,\"batch-wait-size\":8,\"enable-chunk-rpc\":true,\"region-cache-ttl\":600,\"store-limit\":0,\"store-liveness-timeout\":\"1s\",\"copr-cache\":{\"capacity-mb\":1000},\"copr-req-timeout\":60000000000,\"ttl-refreshed-txn-size\":33554432,\"resolve-lock-lite-threshold\":16,\"max-concurrency-request-limit\":9223372036854775807,\"enable-replica-selector-v2\":true},\"binlog\":{\"enable\":false,\"ignore-error\":false,\"write-timeout\":\"15s\",\"binlog-socket\":\"\",\"strategy\":\"range\"},\"compatible-kill-query\":false,\"pessimistic-txn\":{\"max-retry-count\":256,\"deadlock-history-capacity\":10,\"deadlock-history-collect-retryable\":false,\"pessimistic-auto-commit\":false,\"constraint-check-in-place-pessimistic\":true},\"max-index-length\":3072,\"index-limit\":64,\"table-column-count-limit\":1017,\"graceful-wait-before-shutdown\":0,\"alter-primary-key\":false,\"treat-old-version-utf8-as-utf8mb4\":true,\"enable-table-lock\":false,\"delay-clean-table-lock\":0,\"split-region-max-num\":1000,\"top-sql\":{\"receiver-address\":\"\"},\"repair-mode\":false,\"repair-table-list\":[],\"isolation-read\":{\"engines\":[\"tikv\",\"tiflash\",\"tidb\"]},\"new_collations_enabled_on_first_bootstrap\":true,\"experimental\":{\"allow-expression-index\":false},\"skip-register-to-dashboard\":false,\"enable-telemetry\":false,\"labels\":{},\"enable-global-index\":false,\"deprecate-integer-display-length\":false,\"enable-enum-length-limit\":true,\"stores-refresh-interval\":60,\"enable-tcp4-only\":false,\"enable-forwarding\":false,\"max-ballast-object-size\":0,\"ballast-object-size\":0,\"transaction-summary\":{\"transaction-summary-capacity\":500,\"transaction-id-digest-min-duration\":2147483647},\"enable-global-kill\":true,\"enable-32bits-connection-id\":true,\"initialize-sql-file\":\"\",\"enable-batch-dml\":false,\"mem-quota-query\":1073741824,\"oom-action\":\"cancel\",\"oom-use-tmp-storage\":true,\"check-mb4-value-in-utf8\":true,\"enable-collect-execution-info\":true,\"plugin\":{\"dir\":\"/data/deploy/plugin\",\"load\":\"\"},\"max-server-connections\":0,\"run-ddl\":true,\"disaggregated-tiflash\":false,\"autoscaler-type\":\"aws\",\"autoscaler-addr\":\"tiflash-autoscale-lb.tiflash-autoscale.svc.cluster.local:8081\",\"is-tiflashcompute-fixed-pool\":false,\"autoscaler-cluster-id\":\"\",\"use-autoscaler\":false,\"tidb-max-reuse-chunk\":64,\"tidb-max-reuse-column\":256,\"tidb-enable-exit-check\":false,\"in-mem-slow-query-topn-num\":30,\"in-mem-slow-query-recent-num\":500}"]
[2024/05/17 15:34:09.161 +00:00] [ERROR] [advancer.go:400] ["listen task meet error, would reopen."] [error=EOF]
[2024/05/17 15:34:09.226 +00:00] [ERROR] [tso_client.go:365] ["[tso] update connection contexts failed"] [dc=global] [error="rpc error: code = Canceled desc = context canceled"]
=========== ERROR EXIT [1]: FULL tidb.log END ==============
[Pipeline] }
Cache not saved (inner-step execution failed)
[Pipeline] // cache
[Pipeline] }
[Pipeline] // dir
Post stage
[Pipeline] script
[Pipeline] {
          ✓ should support Model.destroy()
[Pipeline] echo
Test failed, archive the log
[Pipeline] }
[Pipeline] // script
[Pipeline] }
[Pipeline] // stage
[Pipeline] }
[Pipeline] // container
[Pipeline] }
[Pipeline] // withEnv
          in combination with allowNull
            ✓ sets the column to not allow null
[Pipeline] }
[Pipeline] // node
[Pipeline] }
[Pipeline] // podTemplate
[Pipeline] }
[Pipeline] // withEnv
        field and attribute name is the same
[Pipeline] }
[Pipeline] // stage
[Pipeline] }
Failed in branch Matrix - TEST_DIR = 'typeorm_test'
Sending interrupt signal to process
Killing processes
          ✓ bulkCreate should work
kill finished with exit code 0
          ✓ find with where should work
Terminated
script returned exit code 143
[Pipeline] }
Cache not saved (inner-step execution failed)
[Pipeline] // cache
[Pipeline] }
[Pipeline] // dir
[Pipeline] }
[Pipeline] // stage
[Pipeline] }
[Pipeline] // container
[Pipeline] }
[Pipeline] // withEnv
[Pipeline] }
[Pipeline] // node
[Pipeline] }
[Pipeline] // podTemplate
[Pipeline] }
[Pipeline] // withEnv
[Pipeline] }
[Pipeline] // stage
[Pipeline] }
Failed in branch Matrix - TEST_DIR = 'sequelize_test'
[Pipeline] // parallel
[Pipeline] }
[Pipeline] // stage
[Pipeline] }
[Pipeline] // timeout
[Pipeline] }
[Pipeline] // withEnv
[Pipeline] }
[Pipeline] // container
[Pipeline] }
[Pipeline] // withEnv
[Pipeline] }
[Pipeline] // node
[Pipeline] }
[Pipeline] // podTemplate
[Pipeline] End of Pipeline
ERROR: script returned exit code 1
Finished: FAILURE