query builder > relation-id > many-to-many > embedded
✔ should load ids when loadRelationIdAndMap used on embedded and nested embedded tables (38ms)
query builder > relation-id > many-to-many > embedded-with-multiple-pk
owner side
✔ should load ids when loadRelationIdAndMap used on embedded table and each table have primary key (51ms)
inverse side
✔ should load ids when loadRelationIdAndMap used on embedded table and each table have primary key (50ms)
query builder > relation-id > many-to-many > multiple-pk
owner side
✔ should load ids when both entities have multiple primary keys
✔ should load ids when only one entity have multiple primary key
✔ should load ids when both entities have multiple primary keys and additional condition used (39ms)
✔ should load ids when both entities have multiple primary keys and related entity does not have inverse side
✔ should load ids when loadRelationIdAndMap used on nested relation (52ms)
inverse side
✔ should load ids when both entities have multiple primary keys
✔ should load ids when only one entity have multiple primary key
✔ should load ids when both entities have multiple primary keys and additional condition used (39ms)
✔ should load ids when loadRelationIdAndMap used on nested relation (51ms)
query builder > relation-id > many-to-one > basic-functionality
✔ should load ids when loadRelationIdAndMap used
✔ should load ids when loadRelationIdAndMap used and target entity has multiple primary keys
✔ should load ids when loadRelationIdAndMap used on nested relation and target entity has multiple primary keys
query builder > relation-id > many-to-one > embedded
✔ should load ids when loadRelationIdAndMap used on embedded and nested embedded tables
query builder > relation-id > many-to-one > embedded-with-multiple-pk
✔ should load ids when loadRelationIdAndMap used on embedded table and each table have primary key
query builder > relation-id > many-to-one > multiple-pk
✔ should load ids when both entities have multiple primary keys
✔ should load ids when only one entity have multiple primary keys
✔ should load ids when both entities have multiple primary keys and related entity does not have inverse side
✔ should load ids when loadRelationIdAndMap used on nested relation
query builder > relation-id > one-to-many > basic-functionality
✔ should load id when loadRelationIdAndMap used with OneToMany relation
✔ should load id when loadRelationIdAndMap used with additional condition
✔ should load id when loadRelationIdAndMap used on nested relation (54ms)
query builder > relation-id > one-to-many > embedded
✔ should load ids when loadRelationIdAndMap used on embedded and nested embedded tables
query builder > relation-id > one-to-many > embedded-with-multiple-pk
✔ should load ids when loadRelationIdAndMap used on embedded table and each table have primary key (46ms)
query builder > relation-id > one-to-many > multiple-pk
✔ should load ids when both entities have multiple primary keys
✔ should load ids when only one entity have multiple primary keys (38ms)
✔ should load ids when both entities have multiple primary keys and additional condition used (39ms)
✔ should load ids when loadRelationIdAndMap used on nested relation (47ms)
query builder > relation-id > one-to-one > basic-functionality
✔ should load ids when loadRelationIdAndMap used with OneToOne owner side relation
✔ should load id when loadRelationIdAndMap used with OneToOne inverse side relation
query builder > relation-id > one-to-one > embedded
✔ should load ids when loadRelationIdAndMap used on embedded and nested embedded tables
query builder > relation-id > one-to-one > embedded-with-multiple-pk
✔ should load ids when loadRelationIdAndMap used on embedded table and each table have primary key
query builder > relation-id > one-to-one > multiple-pk
owner side
✔ should load ids when both entities have multiple primary keys
✔ should load ids when only one entity have multiple primary keys
✔ should load ids when both entities have multiple primary keys and related entity does not have inverse side
✔ should load ids when loadRelationIdAndMap used on nested relation
inverse side
✔ should load ids when both entities have multiple primary keys
✔ should load ids when only one entity have multiple primary keys
✔ should load ids when loadRelationIdAndMap used on nested relation
query builder > relational with many > add and remove many to many inverse
✔ should add entity relation of a given entity by entity objects (45ms)
✔ should add entity relation of a given entity by entity id
✔ should add entity relation of a given entity by entity id map (39ms)
✔ should add entity relation of a multiple entities (39ms)
✔ should add multiple entities into relation of a multiple entities (40ms)
query builder > relational with many > add and remove many to many
✔ should add entity relation of a given entity by entity objects (44ms)
✔ should add entity relation of a given entity by entity id (42ms)
✔ should add entity relation of a given entity by entity id map (41ms)
✔ should add entity relation of a multiple entities (42ms)
✔ should add multiple entities into relation of a multiple entities (38ms)
query builder > relational query builder > add operation > one to many relation
✔ should add entity relation of a given entity by entity objects (39ms)
✔ should add entity relation of a given entity by entity id (38ms)
✔ should add entity relation of a given entity by entity id map (39ms)
✔ should add multiple entities into relation of a multiple entities (40ms)
✔ should handle addAndRemove method as well (48ms)
query builder > relational with many > load many
✔ should load relation entity of a given entity object
✔ should load relation entity of a given entity id map
✔ should load relation entity of a given entity id
query builder > relational query builder > load operation > many-to-one and one-to-one relations
✔ should load relation entity of a given entity object
✔ should load relation entity of a given entity id (93ms)
✔ should load relation entity of a given id (97ms)
query builder > relational query builder > set operation > many to one relation
✔ should set entity relation of a given entity by entity objects (86ms)
✔ should set entity relation of a given entity by entity id (88ms)
✔ should set entity relation of a given entity by entity id map (101ms)
✔ should set entity relation of a multiple entities (101ms)
query builder > relational query builder > set operation > one-to-one non owner side
✔ should set entity relation of a given entity by entity objects (117ms)
✔ should set entity relation of a given entity by entity id (115ms)
✔ should set entity relation of a given entity by entity id map (84ms)
✔ should raise error when setting entity relation of a multiple entities (83ms)
query builder > relational query builder > set operation > one-to-one relation
✔ should set entity relation of a given entity by entity objects (136ms)
✔ should set entity relation of a given entity by entity id (118ms)
✔ should set entity relation of a given entity by entity id map (123ms)
✔ should raise error when setting entity relation of a multiple entities (98ms)
query builder > select
✔ should append all entity mapped columns from main selection to select statement
✔ should append all entity mapped columns from main selection to SELECT DISTINCT statement
✔ should append all entity mapped columns from both main selection and join selections to select statement
✔ should append entity mapped columns from both main alias and join aliases to select statement
✔ should append entity mapped columns to select statement, if they passed as array
✔ should append raw sql to select statement
✔ should append raw sql and entity mapped column to select statement
✔ should not create alias for selection, which is not entity mapped column
✔ Support max execution time
✔ Support using certain index
with relations and where clause
many-to-one
✔ should craft query with exact value
✔ should craft query with FindOperator
✔ should craft query with Raw
one-to-many
✔ should craft query with exact value
✔ should craft query with FindOperator
many-to-many
✔ should craft query with exact value
✔ should craft query with FindOperator
one-to-one
✔ should craft query with exact value
✔ should craft query with FindOperator
deeply nested relations
✔ should craft query with exact value
✔ should craft query with FindOperator
query execution and retrieval
✔ should return a single entity for getOne when found
✔ should return undefined for getOne when not found
✔ should return a single entity for getOneOrFail when found
✔ should throw an Error for getOneOrFail when not found
where-in-ids
✔ should create expected query with simple primary keys
✔ should create expected query with composite primary keys
✔ should create expected query with composite primary keys with missing value
query builder > find with the global condition of "non-deleted" and eager relation
✔ The global condition of "non-deleted" should be set for the entity with delete date columns and eager relation (59ms)
✔ The global condition of "non-deleted" should not be set when "withDeleted" is called (57ms)
query builder > find with the global condition of "non-deleted"
✔ The global condition of "non-deleted" should be set for the entity with delete date columns (55ms)
✔ The global condition of "non-deleted" should not be set when "withDeleted" is called (50ms)
query builder > soft-delete
✔ should perform soft deletion and recovery correctly
✔ should soft-delete and restore properties inside embeds as well (64ms)
✔ should perform soft delete with limit correctly (40ms)
✔ should perform restory with limit correctly (43ms)
✔ should throw error when delete date column is missing
✔ should find with soft deleted relations (64ms)
query builder > sub-query
✔ should execute sub query in where string using subQuery method (100ms)
✔ should execute sub query in where function using subQuery method (74ms)
✔ should execute sub query in where function using subQuery method (80ms)
✔ should execute sub query using different query builder (84ms)
✔ should execute sub query in from expression (using different query builder) (74ms)
✔ should execute sub query in from expression (using from's query builder) (80ms)
✔ should execute sub query in from expression (using from's query builder) (83ms)
✔ should execute sub query in from expression as second from expression (91ms)
✔ should execute sub query in selects (78ms)
✔ should execute sub query in selects (using provided sub query builder) (89ms)
- should execute sub query in joins (using provided sub query builder)
- should execute sub query in joins with subquery factory (as selection)
- should execute sub query in joins as string (as selection)
query builder > time-travel-query
✔ should execute time travel query without options
✔ should execute time travel query with options
✔ should execute time travel query with 'skip' and 'take' options
✔ should execute time travel query with JOIN and skip/take options
✔ should execute time travel query with JOIN and limit/offset options
query builder > update
✔ should perform updation correctly
✔ should be able to use sql functions
✔ should update and escape properly
✔ should update properties inside embeds as well
✔ should perform update with limit correctly
✔ should throw error when update value is missing
✔ should throw error when update value is missing 2
✔ should throw error when update property in set method is unknown
✔ should throw error when unknown property in where criteria
query runner > add column
- should correctly add column and revert add
query runner > change column
- should correctly change column and revert change
- should correctly change column 'isGenerated' property and revert change
✔ should correctly change generated as expression
query runner > create and drop database
✔ should correctly create and drop database and revert it (1016ms)
query runner > create and drop schema
✔ should correctly create and drop schema and revert it
query runner > create check constraint
✔ should correctly create check constraint and revert creation
query runner > create exclusion constraint
✔ should correctly create exclusion constraint and revert creation
query runner > create foreign key
✔ should correctly create foreign key and revert creation (2394ms)
query runner > create index
✔ should correctly create index and revert creation (3286ms)
query runner > create primary key
✔ should correctly create primary key and revert creation (3418ms)
query runner > create table
✔ should correctly create table from simple object and revert creation (269ms)
✔ should correctly create table from Entity (75ms)
✔ should correctly create table with all dependencies and revert creation (1185ms)
✔ should correctly create table with different `Unique` definitions (553ms)
✔ should correctly create table with different `withoutRowid` definitions
query runner > create unique constraint
✔ should correctly create unique constraint and revert creation
query runner > create view
✔ should correctly create VIEW and revert creation
✔ should correctly create MATERIALIZED VIEW and revert creation
query runner > drop check constraint
✔ should correctly drop check constraint and revert drop
query runner > drop column
when columns are instances of TableColumn
- should correctly drop column and revert drop
when columns are strings
- should correctly drop column and revert drop
query runner > drop exclusion constraint
✔ should correctly drop exclusion constraint and revert drop
query runner > drop foreign key
✔ should correctly drop foreign key and revert drop (213ms)
query runner > drop index
✔ should correctly drop index and revert drop (1685ms)
query runner > drop primary key
- should correctly drop primary key and revert drop
query runner > drop table
✔ should correctly drop table without relations and revert drop (530ms)
✔ should correctly drop table with relations and revert drop (909ms)
query runner > drop unique constraint
✔ should correctly drop unique constraint and revert drop
query runner > drop view
✔ should correctly drop VIEW and revert dropping
✔ should correctly drop MATERIALIZED VIEW and revert dropping
query runner > has column
✔ should correctly check if column exist
query runner > implicit results
✔ should return results for Oracle Stored Procedure with Implicit Results
query runner > rename column
✔ should correctly rename column and revert rename (3709ms)
- should correctly rename column with all constraints and revert rename
- should correctly rename column with all constraints in custom table schema and database and revert rename
query runner > rename table
✔ should correctly rename table and revert rename (357ms)
- should correctly rename table with all constraints depend to that table and revert rename
- should correctly rename table with custom schema and database and all its dependencies and revert rename
query runner > stream
✔ should stream data (50ms)
relations > custom-referenced-column-name
many-to-one
✔ should load related entity when relation use custom referenced column name
✔ should load related entity when relation defined with empty join column
✔ should load related entity when relation defined without reference column name
✔ should load related entity when relation defined without column name
✔ should load related entity when relation defined without reference column name and relation does not have relation column in entity
✔ should persist relation when relation sets via join column
one-to-one
✔ should load related entity when relation use custom referenced column name
✔ should load related entity when relation defined without column name
✔ should load related entity when relation defined without reference column name
✔ should load related entity when relation defined without column name
✔ should load related entity when relation defined without reference column name and relation does not have relation column in entity
✔ should persist relation when relation sets via join column
relations > eager relations > basic
✔ should load all eager relations when object is loaded (53ms)
✔ should not load eager relations when query builder is used
relations > eager relations > circular eager relations
✔ should throw error if eager: true is set on both sides of relationship
relations > eager relations > lazy nested eager relations
✔ should load all eager relations nested inside a lazy relation (51ms)
basic-lazy-relations
✔ should persist and hydrate successfully on a relation without inverse side
✔ should persist and hydrate successfully on a relation with inverse side
✔ should persist and hydrate successfully on a one-to-one relation with inverse side loaded from entity schema
✔ should persist and hydrate successfully on a many-to-one relation without inverse side
✔ should persist and hydrate successfully on a many-to-one relation with inverse side
✔ should persist and hydrate successfully on a one-to-many relation
✔ should persist and hydrate successfully on a one-to-one relation owner side
✔ should persist and hydrate successfully on a one-to-one relation inverse side
✔ should successfully load relations within a transaction
✔ should successfully load relations outside a transaction with entity generated within a transaction
lazy-relations-loading-via-base-entity-finders
✔ works
named-columns-lazy-relations
✔ should persist and hydrate successfully on a relation without inverse side
✔ should persist and hydrate successfully on a relation with inverse side
✔ should persist and hydrate successfully on a many-to-one relation without inverse side
✔ should persist and hydrate successfully on a many-to-one relation with inverse side
✔ should persist and hydrate successfully on a one-to-many relation
✔ should persist and hydrate successfully on a one-to-one relation owner side
✔ should persist and hydrate successfully on a one-to-one relation inverse side
named-tables-lazy-relations
✔ should persist and hydrate successfully on a relation without inverse side
✔ should persist and hydrate successfully on a relation with inverse side
✔ should persist and hydrate successfully on a many-to-one relation without inverse side
✔ should persist and hydrate successfully on a many-to-one relation with inverse side
✔ should persist and hydrate successfully on a one-to-many relation
✔ should persist and hydrate successfully on a one-to-one relation owner side
✔ should persist and hydrate successfully on a one-to-one relation inverse side
named-tables-and-columns-lazy-relations
✔ should persist and hydrate successfully on a relation without inverse side
✔ should persist and hydrate successfully on a relation with inverse side
✔ should persist and hydrate successfully on a many-to-one relation without inverse side
✔ should persist and hydrate successfully on a many-to-one relation with inverse side
✔ should persist and hydrate successfully on a one-to-many relation
✔ should persist and hydrate successfully on a one-to-one relation owner side
✔ should persist and hydrate successfully on a one-to-one relation inverse side
relations > multiple-primary-keys > many-to-many
owning side
✔ should load related entity when JoinTable used without options
✔ should load related entity when JoinTable used with options
✔ should load related entity when JoinTable references with non-primary columns
✔ should load related entity when both entities have multiple primary columns and JoinTable used without options
✔ should load related entity when both entities have multiple primary columns and JoinTable used with options
✔ should load related entity when both entities have multiple primary columns and JoinTable references with non-primary columns
inverse side
✔ should load related entity when JoinTable used without options
✔ should load related entity when JoinTable used with options
✔ should load related entity when JoinTable references with non-primary columns
✔ should load related entity when both entities have multiple primary columns and JoinTable used without options
✔ should load related entity when both entities have multiple primary columns and JoinTable used with options
✔ should load related entity when both entities have multiple primary columns and JoinTable references with non-primary columns
relations > multiple-primary-keys > many-to-one
owning side
✔ should load related entity when JoinColumn is not specified
✔ should load related entity when JoinColumn is specified without options (51ms)
✔ should load related entity when JoinColumn is specified with options
✔ should load related entity when JoinColumn references on to non-primary columns
inverse side
✔ should load related entity when JoinColumn is not specified
✔ should load related entity when JoinColumn is specified without options
✔ should load related entity when JoinColumn is specified with options
✔ should load related entity when JoinColumn references on to non-primary columns
relations > multiple-primary-keys > one-to-many
✔ should correctly insert relation items
✔ should correctly load relation items
✔ should correctly update relation items
✔ should correctly delete relation items
relations > multiple-primary-keys > one-to-one
owning side
✔ should load related entity when JoinColumn is specified without options
✔ should load related entity when JoinColumn is specified with options
✔ should load related entity when JoinColumn references on to non-primary columns
✔ should load related entity when both entities have multiple primary columns and JoinColumn defined without options
✔ should load related entity when both entities have multiple primary columns and JoinColumn defined with options
✔ should load related entity when both entities have multiple primary columns and JoinColumn references on to non-primary columns
inverse side
✔ should load related entity when JoinColumn is specified without options
✔ should load related entity when both entities have multiple primary columns and JoinColumn defined without options
✔ should load related entity when both entities have multiple primary columns and JoinColumn defined with options
✔ should load related entity when JoinColumns references on to non-primary columns
✔ should load related entity when both entities have multiple primary columns and JoinColumn defined with options
✔ should load related entity when both entities have multiple primary columns and JoinColumn references on to non-primary columns
relations > multiple-primary-keys > other-cases
✔ should load related entity when entity uses relation ids as primary id (46ms)
relations > relation mapped to relation with different name (#56)
- should work perfectly
relations > relation with primary key
many-to-one with primary key in relation
✔ should work perfectly
repository > aggregate methods
sum
✔ should return the aggregate sum
✔ should return null when 0 rows match the query
average
✔ should return the aggregate average
✔ should return null when 0 rows match the query
minimum
✔ should return the aggregate minimum
✔ should return null when 0 rows match the query
maximum
✔ should return the aggregate maximum
✔ should return null when 0 rows match the query
repository > basic methods
target
✔ should return instance of the object it manages
hasId
✔ should return true if entity has an id
✔ should return false if entity does not have an id
createQueryBuilder
✔ should create a new query builder with the given alias
create
✔ should create a new instance of the object we are working with
✔ should create a new empty object if entity schema is used
✔ should create a new empty object if entity schema with a target is used
✔ should create an entity and copy to it all properties of the given plain object if its given
createMany
✔ should create entities and copy to them all properties of the given plain object if its given
preload
✔ should preload entity from the given object with only id
✔ should preload entity and all relations given in the object
merge
✔ should merge multiple entities
✔ should merge both entities and plain objects
save
✔ should update existing entity using transformers
upsert
- should first create then update an entity
✔ should bulk upsert
- should not overwrite unspecified properties
✔ should skip update when nothing has changed
✔ should upsert with embedded columns
✔ should upsert on one-to-one relation
✔ should bulk upsert with embedded columns
✔ should throw if using an unsupported driver
✔ should throw if using indexPredicate with an unsupported driver
preload also should also implement merge functionality
✔ if we preload entity from the plain object and merge preloaded object with plain object we'll have an object from the db with the replaced properties by a plain object's properties
query
✔ should execute the query natively and it should return the result
repository > clear method
✔ should remove everything (378ms)
✔ called from entity managed should remove everything as well (375ms)
repository > decrement method
basic
✔ should decrement value
✔ should accept string as input and decrement value
✔ should return UpdateResult
✔ should throw an error if column property path was not found
✔ should throw an error if input value is not number
bigint
✔ should decrement value
embeded entities
✔ should decrement value
repository > deleteById methods
✔ remove using deleteById method should delete successfully
✔ remove using removeByIds method should delete successfully
repository > find methods
count
✔ should return a full count when no criteria given (244ms)
✔ should return a count of posts that match given criteria (244ms)
✔ should return a count of posts that match given multiple criteria (247ms)
✔ should return a count of posts that match given find options (263ms)
✔ should return a count of posts that match both criteria and find options (262ms)
exists
✔ should return a True when no criteria given (258ms)
✔ should return True when matches the given criteria (293ms)
✔ should return True when matches the given multiple criteria (261ms)
✔ should return True when matches the given find options (249ms)
✔ should return True when matches both criteria and find options (253ms)
find and findAndCount
✔ should return everything when no criteria given (252ms)
✔ should return posts that match given criteria (250ms)
✔ should return posts that match given multiple criteria (247ms)
✔ should return posts that match given find options (257ms)
✔ should return posts that match both criteria and find options (262ms)
findOne
✔ should throw an error when no criteria given (247ms)
✔ should return when criteria given (246ms)
✔ should return when find options given (242ms)
findOne
✔ should return entity by a given id (238ms)
✔ should return entity by a given id and find options (247ms)
findByIds
✔ should return entities by given ids
findOneOrFail
✔ should return entity by a given id (253ms)
✔ should return entity by a given id and find options (251ms)
✔ should throw an error if nothing was found (252ms)
repository > find options
✔ should load relations
✔ should execute select query inside transaction
✔ should select specific columns (39ms)
✔ should select by given conditions
repository > find options > comment
✔ repository should insert comment
repository > find options > cache
✔ repository should cache results properly (1030ms)
repository > find options > locking
✔ should throw error if pessimistic lock used without transaction
- should not throw error if pessimistic lock used with transaction
- should attach pessimistic read lock statement on query if locking enabled
✔ should attach for no key update lock statement on query if locking enabled
✔ should attach for key share lock statement on query if locking enabled
✔ should attach SKIP LOCKED for pessimistic_read
✔ should attach NOWAIT for pessimistic_write
✔ should attach pessimistic write lock statement on query if locking enabled
✔ should attach dirty read lock statement on query if locking enabled
✔ should throw error if optimistic lock used with `find` method
✔ should not throw error if optimistic lock used with `findOne` method
✔ should throw error if entity does not have version and update date columns
✔ should throw error if actual version does not equal expected version
✔ should not throw error if actual version and expected versions are equal
✔ should throw error if actual updated date does not equal expected updated date
✔ should not throw error if actual updated date and expected updated date are equal
✔ should work if both version and update date columns applied
✔ should throw error if pessimistic locking not supported by given driver
✔ should not allow empty array for lockTables
✔ should throw error when specifying a table that is not part of the query
✔ should allow on a left join
✔ should allow using lockTables on all types of locking
✔ should allow locking a relation of a relation
repository > find options > operators
✔ not
✔ lessThan
✔ lessThanOrEqual
✔ not(lessThan)
✔ not(lessThanOrEqual)
✔ moreThan
✔ moreThanOrEqual
✔ not(moreThan)
✔ not(moreThanOrEqual)
✔ equal
✔ not(equal)
✔ ilike
✔ not(ilike)
✔ like
✔ not(like)
✔ between
✔ not(between)
✔ in
✔ not(in)
✔ any
✔ not(any)
✔ isNull
✔ not(isNull)
✔ raw
✔ raw (function)
✔ raw (function with object literal parameters)
✔ should work with ActiveRecord model
✔ or (array syntax)
repository > find options > relations
✔ should not any relations if they are not specified
✔ should load specified relations case 1
✔ should load specified relations case 2
✔ should load specified relations and their sub-relations case 1
✔ should load specified relations and their sub-relations case 2
✔ should load specified relations and their sub-relations case 3
✔ should throw error if specified relations were not found case 1
✔ should throw error if specified relations were not found case 2
✔ should throw error if specified relations were not found case 3
✔ should throw error if specified relations were not found case 4
✔ should throw error if specified relations were not found case 5
✔ should throw error if specified relations were not found case 6
repository > increment method
basic
✔ should increment value
✔ should accept string as input and increment value
✔ should return UpdateResult
✔ should throw an error if column property path was not found
✔ should throw an error if input value is not number
bigint
✔ should increment value
embeded entities
✔ should increment value
repository > set/add/remove relation methods
- add elements to many-to-many from owner side
- add elements to many-to-many from inverse side
- remove elements to many-to-many from owner side
- remove elements to many-to-many from inverse side
- set element to one-to-many relation
- set element to many-to-one relation
- set element to NULL in one-to-many relation
- set element to NULL in many-to-one relation
entity > soft-remove
✔ should perform soft removal and recovery correctly
✔ should throw error when delete date column is missing
repository > the global condtion of "non-deleted" with eager relation
✔ The global condition of "non-deleted" should be set for the entity with delete date columns and eager relation
✔ The global condition of "non-deleted" should not be set when the option "withDeleted" is set to true
repository > the global condtion of "non-deleted"
✔ The global condition of "non-deleted" should be set for the entity with delete date columns
✔ The global condition of "non-deleted" should not be set when the option "withDeleted" is set to true
repository > soft-delete
✔ should perform soft deletion and restoration correctly
repository > soft-remove
✔ should perform soft removal and recovery correctly
✔ should throw error when delete date column is missing
schema builder > add column
✔ should correctly add column (425ms)
schema builder > change check constraint
✔ should correctly add new check constraint
✔ should correctly change check
✔ should correctly drop removed check
schema builder > change column
✔ should correctly change column name (571ms)
✔ should correctly change column length (2690ms)
✔ should correctly change column type (4742ms)
✔ should correctly change column default value (137ms)
- should correctly make column primary and generated
- should correctly change column `isGenerated` property when column is on foreign key
- should correctly change non-generated column on to uuid-generated column
- should correctly change generated column generation strategy
✔ should correctly change column comment (884ms)
✔ should correctly change column type when FK relationships impact it (863ms)
schema builder > change exclusion constraint
✔ should correctly add new exclusion constraint
✔ should correctly change exclusion
✔ should correctly drop removed exclusion
schema builder > change index
✔ should correctly add new index (1679ms)
✔ should correctly change index (1968ms)
✔ should correctly drop removed index (240ms)
✔ should ignore index synchronization when `synchronize` set to false (1703ms)
schema builder > change unique constraint
✔ should correctly add new unique constraint (1712ms)
✔ should correctly change unique constraint (1894ms)
✔ should correctly drop removed unique constraint (234ms)
schema builder > create foreign key
✔ should correctly create foreign key (1958ms)
schema builder > create table
✔ should correctly create tables with all dependencies (6704ms)
schema builder > custom-db-and-schema-sync
custom database
✔ should correctly sync tables with custom schema and database (2797ms)
custom schema
✔ should correctly sync tables with custom schema
✔ should correctly sync tables with `public` schema
custom database and schema
✔ should correctly sync tables with custom schema and database
schema builder > drop column
✔ should correctly drop column (828ms)
schema builder > update primary keys
- should correctly update composite primary keys
- should correctly update composite primary keys when table already have primary generated column
spatial-cockroachdb
✔ should create correct schema with geometry type
✔ should create correct schema with geography type
✔ should create correct schema with geometry indices
✔ should persist geometry correctly
✔ should persist geography correctly
✔ should update geometry correctly
✔ should re-save geometry correctly
✔ should be able to order geometries by distance
spatial-postgres
✔ should create correct schema with Postgres' geometry type
✔ should create correct schema with Postgres' geography type
✔ should create correct schema with Postgres' geometry indices
✔ should persist geometry correctly
✔ should persist geography correctly
✔ should update geometry correctly
✔ should re-save geometry correctly
✔ should be able to order geometries by distance
sqlite driver > busy-timeout
✔ should set the busy_timeout as expected
sqlite driver > enable wal
✔ should set the journal mode as expected
sqlite driver > throws an error when queried after closing connection
✔ should throw
sqlite driver > file open flags
✔ should open a DB with flags as expected
sqljs driver > autosave
✔ should call autoSaveCallback on insert, update and delete
sqljs driver > autosave off
✔ should not call autoSaveCallback when autoSave is disabled
sqljs driver > load
✔ should load from a file
✔ should throw an error if the file doesn't exist
sqljs driver > save
✔ should save to file
✔ should load a file that was saved
sqljs driver > startup
✔ should startup even if the file doesn't exist
✔ should write a new file after first write operation
table inheritance > regular inheritance using extends keyword
✔ should work correctly
table-inheritance > single-table > basic-functionality
✔ should correctly insert, update and delete data with single-table-inheritance pattern (73ms)
✔ should be able to save different child entities in bulk
✔ should be able to find correct child entities when base class is used as entity metadata
table-inheritance > single-table > database-option-inherited
✔ should correctly inherit database option
table-inheritance > single-table > no-type-column
✔ should return subclass in relations
table-inheritance > single-table > non-virtual-discriminator-column
✔ should return non virtual discriminator column as well
table-inheritance > single-table > numeric types
✔ should allow numeric types for the discriminator, including 0
table-inheritance > single-table > relations > many-to-many
owner side
✔ should work correctly with ManyToMany relations (54ms)
inverse side
✔ should work correctly with ManyToMany relations
table-inheritance > single-table > relations > one-to-many
✔ should work correctly with OneToMany relations (52ms)
table-inheritance > single-table > relations > one-to-many-cascade-save
✔ should work correctly with OneToMany relations
transaction > transaction with full isolation support
- should execute all operations in a single transaction with READ UNCOMMITTED isolation level
✔ should execute all operations in a single transaction with READ COMMITTED isolation level
✔ should execute all operations in a single transaction with REPEATABLE READ isolation level
- should execute all operations in a single transaction with SERIALIZABLE isolation level
transaction > transaction with oracle connection partial isolation support
✔ should execute all operations in a single transaction with READ COMMITTED isolation level
✔ should execute all operations in a single transaction with SERIALIZABLE isolation level
transaction > transaction with sqlite connection partial isolation support
✔ should execute all operations in a single transaction with READ UNCOMMITTED isolation level
✔ should execute all operations in a single transaction with SERIALIZABLE isolation level
transaction > nested transaction
✔ should execute operations based on conditions in deeply nested scenario (40ms)
✔ should fail operations when first transaction fails
transaction > return data from transaction
✔ should allow to return typed data from transaction
✔ should allow to return typed data from transaction using type inference
transaction > single query runner
✔ should execute all operations in the method in a transaction
✔ should execute all operations in the method in a transaction (#804)
transaction > transaction with entity manager
✔ should execute all operations in a single transaction
✔ should not save anything if any of operation in transaction fail
transaction > transaction with load many
✔ should loadMany in same transaction with same query runner
tree tables > closure-table
✔ categories should be attached via parent and saved properly
✔ categories should be attached via children and saved properly
✔ categories should be attached via children and saved properly and everything must be saved in cascades
- categories should remove removed children
- sub-category should be removed with all its children
✔ findTrees() tests > findTrees should load all category roots and attached children
✔ findTrees() tests > findTrees should load multiple category roots if they exist
✔ findTrees() tests > findTrees should filter by depth if optionally provided
✔ findDescendantsTree() tests > findDescendantsTree should load all category descendents and nested children
✔ findDescendantsTree() tests > findDescendantsTree should filter by depth if optionally provided
tree tables > materialized-path
✔ attach should work properly
✔ categories should be attached via children and saved properly
✔ categories should be attached via children and saved properly
✔ categories should be attached via children and saved properly and everything must be saved in cascades
✔ findTrees() tests > findTrees should load all category roots and attached children
✔ findTrees() testsfindTrees should load multiple category roots if they exist
✔ findTrees() testsfindTrees should filter by depth if optionally provided
✔ findDescendantsTree() tests > findDescendantsTree should load all category descendents and nested children
✔ findDescendantsTree should filter by depth if optionally provided
✔ should compute path correctly when tree is implicitly saved (cascade: true) through related entity
tree tables > nested-set
✔ attach should work properly
✔ categories should be attached via children and saved properly
✔ categories should be attached via children and saved properly
✔ categories should be attached via children and saved properly and everything must be saved in cascades
✔ findTrees() tests > findTrees should load all category roots and attached children
✔ findTrees() tests > findTrees should filter by depth if optionally provided
✔ findTrees() tests > findTrees should present a meaningful error message when used with multiple roots + nested sets
✔ findDescendantsTree() tests > findDescendantsTree should load all category descendents and nested children
✔ findDescendantsTree() tests > findDescendantsTree should filter by depth if optionally provided
ImportUtils.importOrRequireFile
✔ should import .js file as ESM
✔ should import .js file as CommonJS
✔ should import .mjs file as ESM
✔ should import .cjs file as CommonJS
✔ should import .json file as CommonJS
OrmUtils.mergeDeep
✔ should handle simple values.
✔ should handle ordering and indempotence.
✔ should skip nested promises in sources.
✔ should merge moderately deep objects correctly.
✔ should merge recursively deep objects correctly
✔ should reference copy complex instances of classes.
StringUtils
snakeCase
✔ should convert camelcase to snakecase
✔ should correctly convert an initial capital
✔ should correctly convert strings of capitals
✔ should correctly convert repeating camelcase groups
✔ should do nothing with strings that are already snakecase
✔ should correctly convert mixed strings into snakecase
✔ should correctly convert strings with numbers
✔ should match the examples given in the older implementation
camelCase
✔ should convert snakecase to camelcase
✔ should convert with first capital letter
✔ should correctly convert repeating snakecase groups
✔ should do nothing with strings that are already camelcase
✔ should correctly convert strings with numbers
uuid-cockroach
✔ should make correct schema with CockroachDB uuid type
✔ should persist uuid correctly
✔ should persist uuid correctly when it is generated non primary column
uuid-mssql
✔ should persist uuid correctly when it is generated non primary column
uuid-mysql
✔ should persist uuid correctly when it is generated non primary column
✔ should set generated uuid in the model after save
uuid-oracle
✔ should persist uuid correctly when it is generated non primary column
pgcrypto
✔ should make correct schema with Postgres' uuid type
✔ should persist uuid correctly
✔ should persist uuid correctly when it is generated non primary column
uuid-ossp
✔ should make correct schema with Postgres' uuid type
✔ should persist uuid correctly
✔ should persist uuid correctly when it is generated non primary column
uuid-mysql
✔ should persist uuid correctly when it is generated non primary column
✔ should set generated uuid in the model after save
uuid-spanner
✔ should persist uuid correctly when it is generated non primary column
uuid-sqlite
✔ should persist uuid correctly when it is generated non primary column
view entity > general
✔ should create entity view from query builder definition
✔ should correctly return data from View (44ms)
view entity > mssql
✔ should create entity view from string definition
✔ should correctly return data from View
view entity > mysql
✔ should create entity view from string definition
✔ should correctly return data from View
view entity > oracle
✔ should create entity view from string definition
✔ should correctly return data from View
view entity > postgres
✔ should create entity view from string definition
✔ should not return data without refreshing the materialized view
✔ should correctly return data from View
view entity > sqlite
✔ should create entity view from string definition
✔ should correctly return data from View
views dependencies
✔ should generate drop and create queries in correct order
github issues > #10040 TypeORM synchronize database even if it is up to date
✔ should return an empty array for the upQueries after sync
github issues > #1014 Transaction doesn't rollback
✔ should rollback transaction if some operation failed in it
github issues > #1034 Issue using setter with promises
✔ should set members in circle
github issues > #1042 EntityMetadata.createPropertyPath does not work properly with objects inside entities (date, json, etc.)
✔ should update object columns fine, at the same time embedded should work properly
github issues > #1055 ind with relations not working, correct syntax causes type error
✔ should be able to find by object reference
✔ should not have type errors with the primary key type
github issues > #108 Error with constraint names on postgres
✔ should sync even when there unqiue constraints placed on similarly named columns
github issues > #1089 UUID in ClosureEntity
✔ should correctly work with primary UUID column (2515ms)
github issues > #1099 BUG - QueryBuilder MySQL skip sql is wrong
✔ drivers which does not support offset without limit should throw an exception, other drivers must work fine
github issues > #1113 CreateDateColumn's type is incorrect when using decorator @CreateDateColumn({type: 'timestamp'})
✔ should correctly create date column from @CreateDateColumn decorator and with custom column type
github issues > #1118 findByIds must return empty results if no criteria were passed in an array
✔ drivers which does not support offset without limit should throw an exception, other drivers must work fine
github issues > #1123 load relation eagerly by setting isEager property
✔ should load all eager relations when object is loaded
✔ should not load eager relations when query builder is used
github issues > #1139 mysql primary generated uuid ER_TOO_LONG_KEY
✔ correctly create primary generated uuid column (536ms)
github issues > #114 Can not be parsed correctly the URL of pg.
- should not fail in url parser
github issues > #1140 timestamp column and value transformer causes TypeError
✔ correctly store/load timestamp columns
github issues > #1147 FindOptions should be able to accept custom where condition
- should properly query using custom sql
github issues > #1178 subqueries must work in insert statements
✔ should work fine
github issues > #1200 Update multiple nested embeddeds
✔ should update all embedded entities including the nested ones
github issues > #1210 mongodb does not have multiple entities properly
✔ should save entities properly
github issues > #1233 column updatedDate must appear in the GROUP BY clause or be used in an aggregate function
✔ should filter correctly using findByIds
github issues > #1245 `findByIds` ignores `FindManyOptions`
✔ should filter correctly using findByIds
✔ should filter correctly using findByIds
github issues > #1259 Can't sort by fields added with addSelect
✔ should order by added selects when pagination is used
✔ should order by added selects when pagination is used
github issues > #1261 onDelete property on foreign key is not modified on sync
✔ should modify onDelete property on foreign key on sync (516ms)
github issue > #1282 FEATURE REQUEST - Naming strategy joinTableColumnName if it is called from the owning or owned (inverse) context
✔ NamingStrategyUnderTest#
github issues > #1308 Raw Postgresql Update query result is always an empty array
✔ Update query returns the number of affected rows
github issues > #131 Error with single table inheritance query without additional conditions
✔ should not fail when querying for single table inheritance model without additional conditions
github issues > #1314 UPDATE on json column stores string type
✔ should not store json type as string on update
github issue > #1326 Wrong behavior w/ the same table names in different databases
✔ should not confuse equivalent table names in different databases (46ms)
github issues > #134 Error TIME is converted to 'HH-mm' instead of 'HH:mm
✔ should successfully persist the post with creationDate in HH:mm and return persisted entity
github issues > #1355 Allow explicitly named primary keys, foreign keys, and indices
✔ should set foreign keys their names to given names
github issues > #1369 EntitySubscriber not firing events on abstract class entity
✔ should fire the given event for an abstract entity
github issues > #1377 Add support for `GENERATED ALWAYS AS` in MySQL
- should correctly create table with generated columns
github issues > #1388 nullable: true dons't output 'NULL' in mysql
✔ should correctly create nullable column
github issue > #1397 Spaces at the end of values are removed when inserting
✔ should not trim empty spaces when saving
github issue > #1416 Wrong behavior when fetching an entity that has a relation with its own eager relations
✔ should load eager relations of an entity's relations recursively
github issues > #1427 precision and scale column types with errant behavior
✔ should correctly create column with precision and scale
github issues > #1465 save child and parent entity
✔ account property in accountActivationToken should not be null
github issues > #1476 subqueries
✔ should
github issues > #1493 Error parsing pg connection string
✔ should parse common connection url
✔ should parse url with password contains colons
✔ should parse url with username and password contains at signs
github issues > #1504 Cannot eagerly query Entity with relation more than 3 levels deep
✔ should not throw an error
github issues > #151 joinAndSelect can't find entity from inverse side of relation
✔ should cascade persist successfully
github issues > #1510 entity schema does not support mode=objectId
✔ throws an error because there is no object id defined
✔ should create entities without throwing an error when objectId is defined
github issues > #1532 Array type default value doesnt work. PostgreSQL
✔ can recognize model changes
✔ does not generate when no model changes
github issues > #1545 Typeorm runs insert query instead of update query on save of existing entity for ManyToOne relationships
- should add intial validation data
github issues > #1551 complex example of cascades + multiple primary keys = persistence order
✔ throws an error because there is no object id defined
- throws a "update or delete on table 'message' violates foreign key constraint on table 'recipient'" error on delete
- throws a "null value in column 'userId' violates not-null constraint" error on delete
- throws a "Subject Recipient must have an identifier to perform operation" internal error on delete
github issue > #1569 updateById generates wrong SQL with arrays inside embeddeds
✔ should properly updateById arrays inside embeddeds
github issues > #1576 Entities with null as `id` are merged [@next]
✔ should successfully create object
github issues > #1581 Composite key breaks OneToMany relation
- throws an error because there is no object id defined
github issues > #1584 Cannot read property 'createValueMap' of undefined
✔ should save entities properly
github issues > #1591 Define order of relation data when querying on the main entity
- should query correct number of users with joined data ordering applied
github issues > #1600 Postgres: QueryBuilder insert with Postgres array type bug
✔ should insert successfully using save method
✔ should insert successfully using insert method
github issues > #161 joinAndSelect can't find entity from inverse side of relation
✔ should persist successfully
✔ should return joined relation successfully
github issues > #1615 Datetime2 with any precision result in datetime2(7) in database
✔ should correctly create column with Datetime2 type and any precision
github issues > #1623 NOT NULL constraint failed after a new column is added (SQLite)
✔ should correctly add new column (171ms)
github issues > #163 ManyToMany relation : Cannot read property 'joinColumnName' of undefined
✔ should persist class table child successfully
github issues > #1652 Multiple primary key defined
✔ should correctly create table when multiple primary keys defined and one of them is generated
github issues > #1680 Delete & Update applies to all entities in table if criteria is undefined or empty
✔ Delete & Update should throw an error when supplied with an empty criteria
github issues > #1685 JoinColumn from JoinColum is not considered when inserting new value
- should not fail when inserting a new UserMonth with good PKs from JoinColumn
github issues > #1703 Many to Many with association table returns odd values.
✔ should work as expected
github issues > #1720 Listener not invoked when relation loaded through getter
✔ should work as expected
github issues > #1733 Postgresql driver does not detect/support varying without length specified
✔ should correctly synchronize schema when varchar column length is not specified
github issues > #174 Embeded types confusing with order by
✔ should order organisations correctly when properties are duplicate in its embeddable
github issues > #1748 PrimaryColumn combined with transformer leads to error on save
✔ should work as expected
github issues > #1749 Can't delete tables in non-default schema
✔ should delete entites from tables in different schemas
github issues > #175 ManyToMany relation doesn't put an empty array when the relation is empty
✔ should return post with categories if they are attached to the post
✔ should return post with categories even if post with empty categories was saved
✔ should return post with categories even if post was saved without categories set
github issues > #1751 Create sequence repeatedly when it already exists
✔ should correctly synchronize schema
github issue #1754 Repository.save() always updating ManyToOne relation
✔ should work as expected
github issues > #1758 Synchronization bug in PostgreSQL bug occurs when we explicitly state the default schema as 'public'
postgres, cockroachdb
✔ should correctly synchronize schema when we explicitly state the default schema as 'public'
mssql
✔ should correctly synchronize schema when we explicitly state the default schema as 'public'
github issues > #176 @CreateDateColumn and @UpdateDateColumn does not read back in UTC
✔ should return dates in utc
github issues > #1780 Support for insertion ignore on duplicate error
✔ should save one row without duplicate error in MySQL/MariaDB
✔ should save one row without duplicate error in PostgreSQL
github issues > #1788 One to One does not load relationships.
✔ should work as expected when using find* methods with relations explicitly provided
github issues > #1805 bigint PK incorrectly returning as a number (expecting a string)
✔ should return `bigint` column as string
github issues > #182 enums are not saved properly
✔ should persist successfully with enum values
github issues > #1825 Invalid field values being loaded with long camelCased embedded field names.
✔ should load valid values in embedded with long field names
github issues > #1839 Charset and collation not being carried to JoinTable when generating migration
- should carry charset and collation from original column in to junction column
github issues > #184 [Postgres] Single-Inheritance not working with integer type field
✔ single table inheritance should accept a Integer Type
github issues > #1863 createTable.uniques doesn't work when the columnNames only has one item
✔ should correctly create table with unique constraint (93ms)
github issues > #1883 Synchronization error with default value
✔ should correctly synchronize schema with enum column
github issues > #1887 Having problems with UNIQUEIDENTIFIERS
✔ should correctly insert data
github issues > #1898 Simple JSON breaking in @next
✔ should correctly persist
github issues > #190 too many SQL variables when using setMaxResults in SQLite
✔ should not fail if high max results is used
github issues > #1901 The correct way of adding `ON UPDATE CURRENT_TIMESTAMP` clause to timestamp column
✔ should correctly create and change column with ON UPDATE expression (103ms)
github issues > #1493 Error parsing pg connection string
✔ should parse url with empty password
✔ should parse url without password
github issues > #1926 Update fails for entity with compound relation-based primary key on OneToMany relationship
- Should update OneToMany entity with compound relation-based primary key
github issues > #1929 Select attributes in Find method - mongodb
✔ return column on include in select on find
✔ return column on include in select on findAndCount
✔ return column on include in select on findByIds
✔ return column on include in select on findByIds
github issues > #1960 Migration generator produces duplicated changes
- should not execute any alter queries
github issues > #197 Fails to drop indexes when removing fields
✔ it should drop the column and the referenced index (307ms)
github issues > #1972 STI problem - empty columns
✔ should insert with userId
✔ should insert with ownerId
github issues > #1981 Boolean values not casted properly when used in .find() condition
✔ should be able to find by boolean find
github issues > #1997 enum type not working in postgres when defined in a custom schema
✔ should create table with ENUM column
✔ should be able to read table data with ENUM
✔ should save data with ENUM
✔ 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 column and revert change
✔ should rename ENUM when column renamed and revert rename
✔ should rename ENUM when table renamed and revert rename
github issues > #2005
✔ should be able to find by boolean find
github issues > #2006 Columns are being set to null after saving the entity
✔ should be able to find by boolean find
github issues > #2031 Advanced find options with FKs
✔ find operators should work with relational columns as well
github issues > #204 jsonb array is not persisted correctly
✔ should persist json and jsonb arrays correctly
github issues > #2044 Should not double get embedded column value
✔ Insert query should work with relational columns
github issues > #2065 TypeError: Cannot convert object to primitive value
✔ should save an entity created with Object.create(null)
github issues > #2067 Unhandled promise rejection warning on postgres connection issues
✔ should return a catchable error on connection errors in queries
github issues > #2096 [mysql] Database name isn't read from url
✔ should be possible to define a database by connection url for mysql
github issues > #2103 query builder regression
✔ whereInIds should respect logical operator precedence > single simple primary key (in is used)
✔ whereInIds should respect logical operator precedence > multiple primary keys
github issues > #211 where in query issue
✔ should not fail if WHERE IN expression is used
github issues > #2128 skip preparePersistentValue for value functions
✔ should be able to resolve value functions
github issues > #2131 InsertResult return the same primary key
✔ should get correct insert ids for multiple entities inserted
github issues > #2147 Lazy load JoinColumn with multiple columns name property is ignored for second reference column
- should create multiple column join for lazy loading relationship
github issues > #215 invalid replacements of join conditions
✔ should not do invalid replacements of join conditions
github issues > #219 FindOptions should be able to resolve null values
✔ should properly query null values
github issues > #2199 - Inserting value for @PrimaryGeneratedColumn() for mysql, sqlite and mssql
✔ should allow to explicitly insert primary key value
✔ should reset mssql's INSERT_IDENTITY flag correctly after failed queries
github issue > #2200 Bug - Issue with snake_case naming strategy
✔ Renammed alias allow to query correctly
github issues > #2201 - Create a select query when using a (custom) junction table
✔ Should create only two PM columns ('order_id' and 'user_id') (2362ms)
✔ Should not try to update the junction table when not needed
github issues > #2216 - Ability to capture Postgres notifications in logger
when logNotifications option is NOT enabled
✔ should NOT pass extension setup notices to client
✔ should NOT pass manual notices to client
✔ should NOT pass 'listen -> notify' messages to client
when logNotifications option is enabled
✔ should pass extension setup notices to client
✔ should pass manual notices to client
✔ should pass 'listen -> notify' messages to client
✔ should not interfere with actual queries
github issues > #2251 - Unexpected behavior when passing duplicate entities to repository.save()
✔ should update all entities
✔ should handle cascade updates
github issues > #2253 - inserting multiple child entities fails
✔ should be able to save multiple child entities
github issues > #2259 Missing type for generated columns
✔ Should create table with generated column
github issues > #2286 find operators like MoreThan and LessThan doesn't work properly for date fields
✔ should find a record by its datetime value with find options
✔ should find a record by its datetime value with query builder
✔ should save, update, and load with a date PK
github issues > #2287 - QueryBuilder IN and ANY Fail with .where - Postgres
✔ should allow to explicitly insert primary key value
github issues > #2298 - Repository filtering not considering related columns as filter
✔ should work perfectly
github issues > #2313 - BaseEntity has no findOneOrFail() method
✔ should find the appropriate record when one exists
✔ should throw no matching record exists
github issues > #2331 undefined value is nulling column on update
✔ should not overwrite column with null when passing undefined
github issues > #2333 datetime column showing changed on every schema:sync run
✔ should recognize model changes
✔ should not generate queries when no model changes (94ms)
github issues > #234 and #223 lazy loading does not work correctly from one-to-many and many-to-many sides
✔ should correctly load from one-to-many and many-to-one sides (48ms)
✔ should correctly load from both many-to-many sides (126ms)
github issues > #2364 should generate id value if @Column generated:true is set
✔ should generate id value (1190ms)
github issues > #2376 Naming single column unique constraint with decorator not working as expected
✔ should keep user-specified Unique constraint name
github issues > #2434 QueryBuilder insert for Oracle failed
✔ should insert multiple rows with QueryBuilder
✔ should throw ORA-00001 error if constraint violated when inserting multiple rows
✔ should insert multiple rows of entity with generated columns with QueryBuilder
✔ should still insert one row with QueryBuilder
✔ should still insert multiple rows with save
✔ should still insert one row with save
github issues > #2464 - ManyToMany onDelete option not working
✔ should not delete when onDelete is 'NO ACTION'
✔ should delete when onDelete is not set
github issues > #2499 Postgres DELETE query result is useless
✔ should return correct number of affected rows for mysql, mariadb, postgres
github issues > #2518 TreeRepository.findDescendantsTree does not load descendants when relationship id property exist
✔ should load descendants when findDescendantsTree is called for a tree entity
✔ should load descendants when findTrees are called
github issues > #2557 object looses its prototype before transformer.to()
✔ should give correct object in transformer.to
github issues > #2588 - createQueryBuilder always does left joins on relations
✔ Should allow joins with conditions
github issues > #2632 createQueryBuilder relation remove works only if using ID
✔ should add and remove relations of an entity if given a mix of ids and objects
github issues > #2651 set shouldn't have update statements twice when UpdateDate is in use
✔ should add and remove relations of an entity if given a mix of ids and objects
github issues > #2875 Option to run migrations in 1-transaction-per-migration mode
✔ should fail to run all necessary migrations when transaction is all
✔ should be able to run all necessary migrations when transaction is each
github issues > #2703 Column with transformer is not normalized for update
✔ should transform values when computing changed columns
github issues > #2733 should correctly handle function calls with upercase letters as default values
✔ MSSQL, Sqljs, Sqlite
✔ Postgres
github issues > #2737 MySQLDriver findChangedColumns (fields: width, precision)
✔ should not create migrations for an existing unique index when bigNumberStrings is false
github issues > #2758 Insert fails when related OneToOne entity's primary key is also a foreign key
- should insert person with nested new party
- should insert user with nested new person
- should insert a new user with existing person
- should insert user with existing personId
github issues > #2779 Could we add support for the MySQL/MariaDB SET data type?
✔ should create column with SET datatype
✔ should persist and hydrate sets
github issues > #2800 - Can't override embedded entities in STI implementation
✔ should be able to save entity with embedded entities overriding
github issues > #2809 afterUpdate subscriber entity argument is undefined
✔ if entity has been updated via repository update(), subscriber should get passed entity to change
github issues > #2871 Empty enum array is returned as array with single empty string
✔ should extract array with values from enum array values from 'postgres'
✔ should extract array with one value from enum array with one value from 'postgres'
✔ should extract empty array from empty enum array from 'postgres'
github issues > #2875 runMigrations() function is not returning a list of migrated files
✔ should be able to run all necessary migrations
github issues > #2904 Type DeepPartial issue when used with generics
✔ DeepPartial should correctly handle generics
github issues > #2927 When using base class' custom repository, the discriminator is ignored
✔ should use the correct subclass for inheritance when saving and retrieving concrete instance
✔ should work for deeply nested classes
✔ should work for saving and fetching different subclasses
github issues > #2943 Inappropriate migration generated
✔ should not create migrations for unsigned numeric types with no specified width
github issues > #2965 Reuse preloaded lazy relations
✔ should resuse preloaded lazy relations
github issues > #2984 Discriminator conflict reported even for non-inherited tables
✔ should load entities even with the same discriminator
github issues > #300 support of embeddeds that are not set
✔ embedded with custom column name should persist and load without errors
github issues > #3047 Mysqsl on duplicate key update use current values
✔ should overwrite using current value in MySQL/MariaDB
✔ should overwrite using current value in PostgreSQL
github issues > #306 embeddeds with custom column name don't work
✔ embedded with custom column name should persist and load without errors
github issues > #3076 Postgres enum in schema with default is recreated in every new generated migration
✔ should recognize model changes
✔ should not generate queries when no model changes
✔ should handle `enumName` default change
github issues > #3105 Error with cascading saves using EntityManager in a transaction
✔ error with cascading saves using EntityManager in a transaction
github issues > #3111 Inserting with query builder attempts to insert a default row when values is empty array
✔ should not insert with default values on .values([])
✔ should still error on missing .values()
github issues > #3112 default:null should inserts nulls to database
✔ should insert null when no value specified
github issues > #9316 specify how should interpret null and undefined values in conditions
✔ should find users what money is not null and money is more than 10 and money is less than 100
github issues > #3118 shorten alias names (for RDBMS with a limit) when they are longer than 63 characters
✔ should be able to load deeply nested entities, even with long aliases (100ms)
✔ should shorten table names which exceed the max length
github issues > #3120 Add relation option "createForeignKeyConstraints"
✔ should create foreign key for relation without createForeignKeyConstraints option
✔ should not create foreign key for relation with createForeignKeyConstraints equal false
relation with createForeignKeyConstraints equal false
✔ should work perfectly
github issues > #3142 Unique constraint not created on embedded entity field
✔ should create unique constraint on embedded entity
github issues > #3151 'uuid' in PrimaryGeneratedColumn causes Many-to-Many Relationship to Fail
✔ should work correctly
github issues > #3158 Cannot run sync a second time
✔ can recognize model changes
github issues > #320 Bug in getManyAndCount
✔ should correctly parse type from PrimaryGeneratedColumn options
github issues > #3246 Saving an entity with a 1:1 cascading insert does not return id if entity has nullable many:one relationship
✔ should insert and return the order with id
github issues > #3256 wrong subscriber methods being called
✔ if entity was changed, subscriber should be take updated columns
github issues > #3349 Multiple where conditions with parameters
✔ should work with query builder
✔ should work with findOne
github issues > #3350 ER_DUP_FIELDNAME with simple find
✔ should find without errors
github issues > #3352 sync drops text column
✔ should not drop text column
github issues > #3363 Isolation Level in transaction() from Connection
- should execute operations in READ UNCOMMITED isolation level
- should execute operations in SERIALIZABLE isolation level
github issues > #3374 Synchronize issue with UUID (MySQL)
✔ should not drop primary column again
github issues > #3379 Migration will keep create and drop indexes if index name is the same across tables
✔ should not recreate indices (276ms)
github issues > #3387 named columns
✔ should allow inserting named columns
github issues > #3395 Transform.from does nothing when column is NULL
✔ should run transform from if column is null
github issues > #341 OneToOne relation with referencedColumnName does not work
✔ custom join column name and referencedColumnName
github issues > #3416 Unknown fields are stripped from WHERE clause
should throw FindCriteriaNotFoundError when supplying unknown property in where criteria
✔ find
✔ update
✔ delete
github issues > #3422 cannot save to nested-tree table if schema is used in postgres
✔ should not fail when using schema and nested-tree
github issues > #3443 @JoinTable on entities without synchronization
✔ Should set synchronize: false for @JoinTable when passed to options
github issues > #345 Join query on ManyToMany relations not working
✔ embedded with custom column name should persist and load without errors (50ms)
github issues > #3496 jsonb comparison doesn't work
✔ the entity should not be updated a second time
github issues > #352 double precision round to int in mssql
✔ real number should be successfully stored and loaded from db including value in parameters
github issues > #3534: store regexp
✔ allows entities with regexp columns
github issues > #3536 Sync only works once for enums on entities with capital letters in entity name
✔ should run without throw error
github issues > #3551 array of embedded documents through multiple levels are not handled
✔ should return entity with all these embedded documents
github issues > #3587 do not generate change queries for number based enum types every time
✔ should NOT generate change queries in case enum is not changed
github issues > #3588 Migration:generate issue with onUpdate using mysql 8.0
✔ can recognize model changes
github issues > #3604 FK columns have wrong length when PrimaryGeneratedColumn('uuid') is used.
✔ join column should have the same length with primary column
github issues > #363 Can't save 2 unrelated entity types in a single persist call
✔ entityManager should allow you to save unrelated entities with one persist call
✔ entityManager should allow you to delete unrelated entities with one remove call
github issues > #3636 synchronize drops (and then re-adds) json column in mariadb
✔ should not drop json column
github issues > #3685 Brackets syntax failed when use where with object literal
✔ should accept objects in .where method (github issue #3685)
github issues > #3694 Sync enums on schema sync
✔ should change schema when enum definition changes (223ms)
github issues > #3702 MySQL Spatial Type Support : GeomFromText function is not supported
when legacySpatialSupport: true
- should use GeomFromText
- should provide SRID
- should use AsText
when legacySpatialSupport: false
- should use ST_GeomFromText
- should provide SRID
- should use ST_AsText
github issues > #3737 Should URL-decode the user info of a data source URI
✔ should parse URL with percent-encoded username
✔ should parse URL with percent-encoded password
github issues > #3783 Tree functionality broken
✔ should work correctly
github issues > #3803 column option unique sqlite error
✔ should create unique constraints defined in EntitySchema
github issues > #3828 Conflicting PR to fix postgres schema:log with uppercase table names and enums
✔ schema sync should work when enum type name was changed
github issues > #3847 FEATURE REQUEST - Naming strategy foreign key override name
✔ NamingStrategyUnderTest#
github issues > #3857 Schema inheritance when STI pattern is used
✔ Child classes should have same schema as parent
github issues > #3874 Using an (empty string) enum as the type of a primary key column
✔ should reload entity
github issues > #388 skip and take with string ID don't work
✔ should load posts with string id successfully
github issues > #3946 loadRelationCountAndMap fails cause made a wrong IN calculation, when primary key is string
✔ should load relation count on owner side
✔ should load relation count on owner side with limitation
✔ should load relation count on owner side with additional conditions (64ms)
✔ should load relation count on both sides of relation
✔ should load relation count on inverse side
✔ should load relation count on inverse side with limitation (39ms)
✔ should load relation count on inverse side with additional conditions (50ms)
github issues > #3949 sqlite date hydration is susceptible to corruption
✔ should correctly read date column that was inserted raw in canonical format
✔ should correctly read date column that was inserted raw in iso 8601 format
github issues > #3991 Migration keeps changing @CreateDateColumn/@UpdateDateColumn timestamp column to same definition
postgres
✔ should recognize model changes
✔ should not generate queries when no model changes
cockroachdb
✔ should recognize model changes
✔ should not generate queries when no model changes
oracle
✔ should recognize model changes
✔ should not generate queries when no model changes
sqlite
✔ should recognize model changes
✔ should not generate queries when no model changes
mysql, mariadb
✔ should recognize model changes
✔ should not generate queries when no model changes (129ms)
mssql
✔ should recognize model changes
✔ should not generate queries when no model changes
github issues > #3997 synchronize=true always failing when using decimal column type with a foreign key constraint
✔ should recognize model changes
✔ should not generate queries when no model changes (2019ms)
github issues > #401 special keywords should be escaped in join queries
✔ should escape 'group' keyword properly
github issues > #4060 Fail to insert entity with Buffer type of primary column under some circumstances.
✔ should save entities
github issues > #4096 SQLite support for orUpdate
✔ should overwrite using current value in SQLite
github issues > #4106 Specify enum type name in postgres
✔ should create an enum with the name specified in column options -> enumName
✔ should insert data with the correct enum
github issues > #4147 `SQLITE_ERROR: near "-": syntax error` when use sqlite, simple-enum
✔ should not error while synchronizing when using simple-enum with sqlite
github issues > #4156 QueryExpressionMap doesn't clone all values correctly
✔ should not error when the query builder has been cloned
✔ should not error when the query builder with where statement has been cloned
github issues > #4185 afterLoad() subscriber interface missing additional info available on other events
✔ should invoke afterLoad() with LoadEvent
github issues > #4190 Relation decorators: allow to pass string instead of typeFunction
✔ should work with one-to-one relations
✔ should work with many-to-one/one-to-many relations
✔ should work with many-to-many relations
github issues > #4219 class-transformer-shim: support metadata reflection
✔ should create instances with the correct property types
github issues > #4220 Fix the bug when using buffer as the key.
✔ should use the hex string format of buffer when the primary column is buffer type.
github issues > #423 Cannot use Group as Table name && cannot autoSchemeSync when use alias Entity
✔ should successfully sync schema (99ms)
github issues > #4277 Using cache in findAndCount and getManyAndCount returns 0 as count
✔ getManyAndCount and findAndCount should count correctly when using cacheId
✔ getManyAndCount and findAndCount should count correctly when NOT using cacheId
✔ getManyAndCount and findAndCount should count correctly when NOT using cache
github issues > #433 default value (json) is not getting set in postgreSQL
✔ should successfully set default value in to JSON type column
github issues > #438 how can i define unsigned column?
- should correctly create and change column with UNSIGNED and ZEROFILL attributes
github issues > #4410 allow custom filepath for FileLogger
when no option is passed
✔ writes to the base path
when logPath option is passed as a file
✔ writes to the given filename
when logPath option is passed as a nested path
✔ writes to the given path
github issues > #4415 allow beautify generated migrations
- writes regular migration file when no option is passed
- writes pretty printed file when pretty option is passed
github issues > #4452 InsertQueryBuilder fails on some SQL Expressions values
✔ should be able to use sql functions
github issues > #4513 CockroachDB support for onConflict
✔ should insert if no conflict
✔ should update on conflict with do update
✔ should not update on conflict with do nothing
✔ should update with orUpdate
github issues > #4570 Fix PrimaryColumn decorator modifies passed option
✔ should not modify passed options to PrimaryColumn
github issues > #463 saving empty string array
✔ should not return array with single empty string if empty array was saved
github issues > #4630 Enum string not escaping resulting in broken migrations.
✔ should support enums of strings with apostrophes in them
github issues > #4658 Renaming a column with current_timestamp(6) results in broken SQL
✔ should correctly rename column and revert rename (400ms)
✔ should correctly remove column and revert it back (722ms)
github issues > #4697 Revert migrations running in reverse order.
✔ should revert migrations in the right order
github issues > #47 wrong sql syntax when loading lazy relation
✔ should persist successfully and return persisted entity
github issues > #4701 Duplicate migrations are executed.
✔ should throw error if there're duplicate migrations
github issues > #4719 HStore with empty string values
✔ should handle HStore with empty string keys or values
✔ should not allow 'hstore injection'
github issues > #4753 MySQL Replication Config broken
- should connect without error when using replication
mssql > add lock clause for MSSQL select with join clause
✔ should not have Lock clause
✔ should have WITH (NOLOCK) clause
✔ should have two WITH (NOLOCK) clause
✔ should have three WITH (NOLOCK) clause
✔ should have three WITH (NOLOCK) clause (without relation)
✔ should have WITH (HOLDLOCK, ROWLOCK) clause
✔ should have WITH (UPLOCK, ROWLOCK) clause
✔ should have two WITH (UPDLOCK, ROWLOCK) clause
github issues > #4782 mariadb driver wants to recreate create/update date columns CURRENT_TIMESTAMP(6) === current_timestamp(6)
✔ should not want to execute migrations twice
VersionUtils
isGreaterOrEqual
✔ should return false when comparing invalid versions
✔ should return false when targetVersion is larger
✔ should return true when targetVersion is smaller
✔ should work with mariadb-style versions
github issues > #479 orWhere breaks skip / take
✔ where expression of the skip/take should not break original where query
github issues > #4842 QueryExpressionMap doesn't clone distinct property
✔ should contain correct distinct value after query builder is cloned
github issues > #485 If I set the datatype of PrimaryGeneratedColumn to uuid then it is not giving the uuid to the column.
✔ should persist uuid correctly when it used as PrimaryGeneratedColumn type
github issues > #4897 [MSSQL] Enum column definition removes and recreates constraint overwritting existing data
✔ should recognize model changes
✔ should not generate queries when no model changes
github issues > #493 pagination should work with string primary keys
✔ should work perfectly with string primary keys
github issues > #4947 beforeUpdate subscriber entity argument is undefined
✔ if entity has been updated via repository update(), subscriber should get passed entity to change
github issues > #495 Unable to set multi-column indices
✔ should successfully create indices and save an object
github issues > #4956 create typeorm_metatable when running migrations.
✔ should create typeorm_metadata table when running migrations with views (713ms)
✔ should not create typeorm_metadata table when running migrations if there are no views (788ms)
github issues > #4958 getRepository returns results from another Repo
✔ sql generated is for correct model
github issues > #4980 (Postgres) onUpdate: 'CASCADE' doesn't work on many-to-many relation
✔ should generate onDelete: CASCADE and onUpdate: CASCADE for 'books' side of many-to-many relation
✔ should generate onDelete: NO ACTION and onUpdate: CASCADE for 'authors' side of many-to-many relation
✔ should generate onDelete: NO ACTION and onUpdate: CASCADE for foreign key pointing to Book
✔ should generate onDelete: CASCADE and onUpdate: CASCADE for foreign key pointing to Author
github issues > #499 postgres DATE hydrated as DATETIME object
✔ should return date in a string format
github issues > #5004 expireAfterSeconds 0 can't be passed to Index decorator
✔ should allow expireAfterSeconds 0 to be passed to Index decorator
github issues > #5067 ORA-00972: identifier is too long
✔ generated parameter name is within the size constraints
github issues > #5119 migration with foreign key that changes target
✔ should generate a drop and create step
github issues > #512 Table name escaping in UPDATE in QueryBuilder
✔ should escape table name using driver's escape function in UPDATE
github issues > #513 Incorrect time/datetime types for SQLite
✔ should create datetime column type for datetime in sqlite
✔ should persist correct type in datetime column in sqlite
✔ should create datetime column type for time in sqlite
✔ should persist correct type in datetime column in sqlite
github issues > #5132: Default of -1 (minus 1) generates useless migrations`
-1 (minus 1) in default value
✔ can recognize model changes
✔ does not generate when no model changes
github issues > #5160 (MSSQL) DML statement cannot have any enabled triggers if the statement contains an OUTPUT clause without INTO clause
✔ should update entity model after insertion to MSSQL table with trigger
✔ should update entity model after save to MSSQL table with trigger
github issues > #5174 `selectQueryBuilder.take` messes up the query when using the `ids` parameter
✔ should allow the 'ids' parameter without messing up the query when using .take
github issues > #521 Attributes in UPDATE in QB arent getting replaced
✔ should replace parameters
github issues > #5275 Enums with spaces are not converted properly.
✔ should correctly parse enums of strings with spaces
✔ should correctly parse non-array enums with spaces
github issues > #5365 Generated Identity for Postgres 10+
✔ should produce proper SQL for creating a table with identity column
github issues > #5407 Wrong migration created because of default column value format
✔ can recognize model changes
✔ does not generate when no model changes (99ms)
github issues > #5444 EntitySchema missing support for multiple joinColumns in relations
✔ Update query returns the number of affected rows
github issues > #5478 Setting enumName doesn't change how migrations get generated
✔ should correctly rename enum
github issues > #5501 Incorrect data loading from JSON string for column type 'simple-json'
✔ should correctly store simple-json field (39ms)
✔ should correctly retrieve simple-json field
✔ should throw an error when the data in the database is invalid
github issues > #5520 save does not return generated id if object to save contains a many to one relationship with an undefined id
✔ should generate parents and childs uuid and return them
github issues > #56 relationships only work when both primary keys have the same name
- should persist successfully and return persisted entity
github issues > #5684 eager relation skips children relations
✔ should select children of an eager relation (62ms)
github issues > #5691 RelationId is too slow
✔ should be as fast as separate queries (302ms)
github issues > #57 cascade insert not working with OneToOne relationship
✔ should persist successfully from inverse side
github issues > #5734 insert([]) should not crash
✔ should not crash on insert([])
✔ should still work with a nonempty array
github issues > #5762 `Using URL as a rich column type breaks
✔ should allow assigning URL as a field value
github issues > #58 relations with multiple primary keys
✔ should persist successfully and return persisted entity
github issues > #587 Ordering of fields in composite indexes defined using Index decorator
✔ should preserve field ordering when fields are specified as string[]
github issues > #5871 Migration generate does not play well with mysql enum with parentheses in the enum value
✔ should recognize model changes
✔ should not generate queries when no model changes (110ms)
github issues > #5898 Postgres primary key of type uuid: default value migration/sync not working
✔ should add DEFAULT value when @PrimaryGeneratedColumn('increment') is added
✔ should remove DEFAULT value when @PrimaryGeneratedColumn('increment') is removed
✔ should add DEFAULT value when @PrimaryGeneratedColumn('uuid') is added
✔ should remove DEFAULT value when @PrimaryGeneratedColumn('uuid') is removed
github issues > #5919 Caching won't work with replication enabled
✔ should not another queryRunner for cache with a given masterQueryRunner
✔ should create another queryRunner for cache with a given slaveQueryRunner
github issues > #594 WhereInIds no longer works in the latest version.
✔ should load entities by given simple post ids (non mixed)
github issues > #6066 Column comment string is not escaped during synchronization
✔ should synchronize (104ms)
github issues > #609 Custom precision on CreateDateColumn and UpdateDateColumn
✔ should create `CreateDateColumn` and `UpdateDateColumn` column with custom default
github issues > #6115 Down migration for enums with defaults are wrong
✔ should change schema when enum definition changes
github issues > #6168 fix multiple foreign keys with the same name in a mysql multi-tenanted DB
✔ should only have one foreign key column
github issues > #6195 feature: fake migrations for existing tables
fake run tests
✔ should fail for duplicate column
✔ should not fail for duplicate column when run with the fake option
fake rollback tests
✔ should fail for non-existent column
✔ should not fail for non-existent column when run with the fake option
github issues > #620 Feature Request: Flexibility in Foreign Key names
✔ should work as expected
github issues > #6265 `fix: resolve issue with find with relations returns soft-deleted entities
✔ should soft delete one record in relation table
github issues > #6266 Many identical selects after insert bunch of items
✔ should execute a single SELECT to get inserted default and generated values of multiple entities
github issues > #6284 cli support for cjs extension
✔ will load a cjs file
✔ loads cjs files via DirectoryExportedClassesloader
github issues > #6327 softRemove DeleteDateColumn is null at Susbscriber's AfterUpdate method
✔ should send correct update and delete date columns to after update subscriber
github issues > #6389 MongoDB URI Connection string with query params
✔ should parse correctly mongodb URI
github issues > #6399 Process extraAppendedAndWhereCondition for inherited entity
✔ Query with join and limit for inhered entity
github issues > #6412 Generating migrations when having entities with CreateDateColumn/UpdateDateColumn and default values as CURRENT_TIMESTAMP leads to a lot of redundant queries in resulting migrations
✔ should recognize model changes
✔ should not generate queries when no model changes (105ms)
github issues > #6399 Combining ManyToOne, Cascade, & Composite Primary Key causes Unique Constraint issues
✔ persisting the cascading entities should succeed
✔ persisting the cascading entities without JoinColumn should succeed
✔ persisting the child entity should succeed
github issues > #6442 JoinTable does not respect inverseJoinColumns referenced column width
✔ should generate column widths equal to the referenced column widths
github issues > #6471 Postgres enum is recreated in every new generated migration
✔ should recognize model changes
✔ should not generate queries when no model changes
✔ should handle `enumName` change
github issues > #6540 Enum not resolved if it is from an external file
✔ should recognize model changes
✔ should not generate queries when no model changes (218ms)
github issues > #6552 MongoRepository delete by ObjectId deletes the wrong entity
✔ should delete the correct entity when id column is called _id
✔ should delete the correct entity when id column is not called _id
✔ should delete the correct entity when deleting by _id query
github issues > #6580 DeepPartial does not handle `any` and `{[k: string]}`
✔ DeepPartial should correctly handle any
✔ DeepPartial should correctly handle {[k: string]: any}
github issues > #660 Specifying a RETURNING or OUTPUT clause with QueryBuilder
✔ should create an INSERT statement, including RETURNING or OUTPUT clause (PostgreSQL and MSSQL only)
✔ should perform insert with RETURNING or OUTPUT clause (PostgreSQL and MSSQL only)
✔ should create an UPDATE statement, including RETURNING or OUTPUT clause (PostgreSQL and MSSQL only)
✔ should perform update with RETURNING or OUTPUT clause (PostgreSQL and MSSQL only)
✔ should create a DELETE statement, including RETURNING or OUTPUT clause (PostgreSQL and MSSQL only)
✔ should perform delete with RETURNING or OUTPUT clause (PostgreSQL and MSSQL only)
github issues > #6633 Fulltext indices continually dropped & re-created
- should not create migrations for fulltext indices
github issues > #6636 migration issues with scale & precision
✔ should not create migrations columns with precision
github issues > #6699 MaxListenersExceededWarning occurs on Postgres
✔ queries in a transaction do not cause an EventEmitter memory leak
github issues > #6714 Migration:generate issue with onUpdate using mariadb 10.4
✔ dont change anything
✔ recognizing on update changes
github issues > #6752 column name not been find on unique index decorator
✔ dont change anything
github issues > #6815 RelationId() on nullable relation returns 'null' string
✔ should return null as childId if child doesn't exist
✔ should return string as childId if child exists
github issues > #6833 Entities with JSON key columns are incorrectly grouped
✔ jsonB keys are correctly resolved
✔ jsonB keys can be found
✔ jsonB keys can be found with IN
✔ jsonB keys can be found regardless of order
github issues > #6900 MongoDB ConnectionManager doesn't select given database, creates new database "test" instead
✔ should connect to the expected database
✔ should write data to the correct database
github issues > #6947 Custom primary column for TreeRepository based entities unable to get tree descendants
✔ entities with custom primary column names should work
github issues > #6948 TreeRepository's findRoots query incorrectly when using a custom primary key
✔ entity parent column should work with custom primary column names
github issues > #695 Join columns are not using correct length
✔ should set correct length on to join columns
github issues > #6950 postgres: Inappropiate migration generated for `default: null`
null default
✔ can recognize model changes
✔ does not generate when no model changes (121ms)
null default and nullable
✔ can recognize model changes
✔ does not generate when no model changes (104ms)
github issues > #6958 Promises never get resolved in specific cases
✔ should release all used query runners upon disconnection
github issues > #6977 Relation columns in embedded entities are not prefixed
✔ should correctly assign foreign key columns in embedded entity
github issues > #6990 synchronize drops array columns in postgres if a length is set
✔ should not drop varchar array column on synchronize using postgres driver
github issues > #6995 Generating migrations for UpdateDateColumn should generate on update clause
✔ should create migration with default ON UPDATE clause
github issues > #70 cascade deleting works incorrect
✔ should persist successfully and return persisted entity
github issues > #7002 cascade save fails if the child entity has CreateDateColumn and PK as JoinColumn
- save an entity having a child entity with shared PK and CreatedDateColumn by cascade
github issues > #703.findOne does not return an empty array on OneToMany relationship
✔ should not return anything in joined relation if nothing was found
github issues > #7030
✔ should insert and fetch from the expected column
github issues > #704 Table alias in WHERE clause is not quoted in PostgreSQL
✔ should return user by a given email and proper escape 'user' keyword
github issues > #7041 When requesting nested relations on foreign key primary entities, relation becomes empty entity rather than null
✔ should return null when requested nested relations are empty on OneToOne relation
✔ should return [] when requested nested relations are empty on OneToMany relation
github issues > #7065 ChildEntity type relationship produces unexpected results
✔ should join child entity with discriminator value condition
github issues > #7068
✔ categories should be attached via parent and saved properly
✔ categories should be attached via children and saved properly
✔ categories should be attached via children and saved properly and everything must be saved in cascades
- categories should remove removed children
- sub-category should be removed with all its children
github issues > #7079 Error when sorting by an embedded entity while using join and skip/take
✔ should be able to getMany with join and sorting by an embedded entity column while user take and skip
github issues > #7087 Allow to specify transaction property for individual migrations
✔ should fail to run all necessary migrations when transaction is all and there are transaction overrides
✔ should set correct transaction mode when transaction is each
✔ should set correct transaction mode when transaction is none
github issues > #71 ManyToOne relation with custom column name persistence fails
✔ should persist successfully entity successfully with its many-to-one relation
github issues > #7100 MSSQL error when user requests additional columns to be returned
✔ should return user requested columns
github issues > #7106 shorten sequence names (for RDBMS with a limit) when they are longer than 63 characters
✔ should be able to work with long sequence name with short table name
✔ should be able to work with long sequence name with long table name
github issues > #7109 stream() bug from 0.2.25 to 0.2.26 with postgresql
✔ should release the QueryRunner created by a SelectQueryBuilder
github issues > #7110: Typeorm Migrations ignore existing default value on column`
double type conversion in default value
✔ can recognize model changes
✔ does not generate when no model changes
github issues > #7113 Soft deleted docs still being pulled in Mongodb
✔ should not pull soft deleted docs with find
✔ should not pull soft deleted docs with findAndCount
✔ should not pull soft deleted docs with findOne
github issues > #7146 Lazy relations resolve to 'undefined' instead of 'null'
lazy-loaded relations
✔ should return null if ManyToOne relation has NULL in database
✔ should return null if OneToOne+JoinColumn relation has NULL in database
✔ should return null if OneToOne relation has NULL in database
lazy-loaded relations included in 'relations' find option
✔ should return null if ManyToOne relation has NULL in database
✔ should return null if OneToOne+JoinColumn relation has NULL in database
✔ should return null if OneToOne relation has NULL in database
eager-loaded relations
✔ should return null if ManyToOne relation has NULL in database
✔ should return null if OneToOne+JoinColumn relation has NULL in database
✔ should return null if OneToOne relation has NULL in database
github issues > #7155
- (Closure/SingleID/Save) Update without parent
- (Closure/SingleID/Save) Update without tree change
- (Closure/SingleID/Save) Set leaf entity as root
- (Closure/SingleID/Save) Move leaf with multi root
- (Closure/SingleID/Save) Move branch with single root
- (Closure/SingleID/Save) Move branch with single root via children
- (Closure/SingleID/Save) Move multiple branches with single root via children
- (Closure/SingleID/Save) Remove and re-add parent
- (Closure/SingleID/Remove) Remove leaf with multi root
- (Closure/SingleID/Remove) Remove branch with single root
- (Closure/SingleID/Remove) Remove multiple branches with single root
- (Nested/SingleID/Save) Update without tree change
- (Nested/SingleID/Save) Set multiple root entities
- (Nested/SingleID/Save) Set leaf entity as root
- (Nested/SingleID/Save) Move leaf with single root
- (Nested/SingleID/Save) Move branch with single root
- (Nested/SingleID/Save) Move branch with single root via children
- (Nested/SingleID/Save) Move multiple branches with single root via children
- (Nested/SingleID/Remove) Remove leaf with single root
- (Nested/SingleID/Remove) Remove branch with single root
- (Nested/SingleID/Remove) Remove multiple branches with single root
- (Materialized/SingleID/Save) Update without parent
- (Materialized/SingleID/Save) Update without tree change
- (Materialized/SingleID/Save) Set leaf entity as root
- (Materialized/SingleID/Save) Move leaf with multi root
- (Materialized/SingleID/Save) Move branch with single root
- (Materialized/SingleID/Save) Move branch with single root via children
- (Materialized/SingleID/Save) Move multiple branches with single root via children
- (Materialized/SingleID/Remove) Remove leaf with multi root
- (Materialized/SingleID/Remove) Remove branch with single root
- (Materialized/SingleID/Remove) Remove multiple branches with single root
- (Nested/MultiID/Save) Update without tree change
- (Nested/MultiID/Save) Set multiple root entities
- (Nested/MultiID/Save) Set leaf entity as root
- (Nested/MultiID/Save) Move leaf with single root
- (Nested/MultiID/Save) Move branch with single root
- (Nested/MultiID/Save) Move branch with single root via children
- (Nested/MultiID/Save) Move multiple branches with single root via children
- (Nested/MultiID/Remove) Remove leaf with single root
- (Nested/MultiID/Remove) Remove branch with single root
- (Nested/MultiID/Remove) Remove multiple branches with single root
- (Materialized/MultiID/Save) Update without parent
- (Materialized/MultiID/Save) Update without tree change
- (Materialized/MultiID/Save) Set leaf entity as root
- (Materialized/MultiID/Save) Move leaf with multi root
- (Materialized/MultiID/Save) Move branch with single root
- (Materialized/MultiID/Save) Move branch with single root via children
- (Materialized/MultiID/Save) Move multiple branches with single root via children
- (Materialized/MultiID/Remove) Remove leaf with multi root
- (Materialized/MultiID/Remove) Remove branch with single root
- (Materialized/MultiID/Remove) Remove multiple branches with single root
github issues > #7155 > tree relations
✔ (Closure) Validate relations
✔ (Nested) Validate relations
✔ (Materialized) Validate relations
github issues > #720 `.save()` not updating composite key with Postgres
✔ should not insert new entity when entity already exist with same primary keys
✔ reproducing second comment issue
github issues > #7203 QueryExpressionMap doesn't clone comment field
✔ should be able to clone comment field
github issues > #7217 Modifying enum fails migration if the enum is used in an array column
✔ should not generate queries when no model changes
✔ should correctly change enum
github issues > #7235 Use "INSERT...RETURNING" in MariaDB.
✔ should allow `DELETE...RETURNING` on MariaDB >= 10.0.5
✔ should allow `INSERT...RETURNING` on MariaDB >= 10.5.0
github issues > #7266 rename table typeorm_metadata name.
✔ should create the typeorm metadata table with a custom name when provided
✔ should have correct views using the custom named metadata table
github issues > #7276 Schema sync not able to find diff correctly and executes same queries on every run
postgres
✔ should recognize model changes
✔ should not generate queries when no model changes
mssql
✔ should recognize model changes
✔ should not generate queries when no model changes
github issues > #7283 Generating Migration on ManyToOne/OneToMany + Primary enum column results in missing enum type in migration output
✔ should create tables with enum primary column (2573ms)
github issues > #736 ClosureEntity should set (composite) primary/unique key in the closure table
✔ should create composite primary key on closure ancestor and descendant
github issues > #7381 Infinite same ALTERs upon startup (mysql, ver 0.2.30)
✔ should recognize model changes
✔ should not generate queries when no model changes (139ms)
github issues > #7401 MongoDB replica set connection string not support with method "parseConnectionUrl" & "buildConnectionUrl"
✔ should parse replicaSet and host list in ConnectionUrl
github issues > #7415 Tree entities with embedded primary columns are not built correctly
✔ should build tree entities with embedded primary columns correctly (49ms)
github issues > #7437 MongoDB options never parse in connectionUrl and after my fix was parse incorrect
✔ should parse options in ConnectionUrl
github issues > #7479 Only first single quote in comments is escaped
✔ should properly escape quotes in comments
github issues > #750 Need option for Mysql's full text search
- should correctly create SPATIAL and FULLTEXT indices
github issues > #752 postgres - count query fails for empty table
✔ should return user by a given email and proper escape 'user' keyword
github issues > #7521 Only first is removed in comments, only first \ is escaped etc.
✔ should recognize model changes
✔ should not generate queries when no model changes (141ms)
✔ should properly escape quotes in comments
github issues > #7523 Do not create duplicate CREATE TYPE migration query when same 'enumName's are exists
✔ should recognize model changes
✔ should not generate queries when no model changes
github issues > #7541 Column of type `enum` throws missing properties error
✔ should recognize model changes
✔ should not generate queries when no model changes
github issues > #7558 Child entities' wrong discriminator value when embedded in parent entity
✔ should use the correct subclass for inheritance when saving & retrieving a single STI entity (one-to-one)
✔ should use the correct subclass for inheritance when saving & retrieving multiple STI entities (one-to-many)
✔ should set the correct discriminators for trees in STI settings
github issues > #7586 Oddly indexed views are not dropped in migration
✔ should generate drop queries for all views
github issues > #7614 Postgres: Custom enum name results in field recreate
✔ should recognize model changes
✔ should not generate queries when no model changes
github issues > #762 Nullable @Embedded inside @Embedded
✔ should work perfectly with all data set
✔ should work perfectly with some data not set (46ms)
✔ should work perfectly without any data set
github issues > #7647 Duplicate migrations when using 'enumName' ColumnOption in an 'enum' type Postgres
✔ should recognize model changes
✔ should not generate queries when no model changes
github issues > #7650 Inappropriate migration generated
✔ should not create migrations for json default which are equivalent
github issues > #7651 Enum that contains functions is not accordingly translated to SQL
entity
✔ should correctly save and retrieve enum fields when declaration merging technique is used and enum contains functions
✔ should correctly save and retrieve enum array
schema
✔ should contain SQL for enum type without function
github issues > #7662 postgres extensions installation should be optional
- should NOT install extensions if option is disabled
- should install extensions if option is undefined
- should install extensions if option is enabled
github issues > #7698 MariaDB STORED columns don't accept [NULL | NOT NULL]
✔ should not generate queries with NULL or NOT NULL for stored columns in mariadb
github issues > #773 @PrimaryGeneratedColumn not returning auto generated id from oracle database
✔ should return auto generated column
github issues > #7760 Mongodb: When field is null in db, typeorm query sets it to undefined
✔ should delete all documents related to search pattern
github issues > #778 TypeORM is ignoring the `type` field when set on a PrimaryGeneratedColumn
✔ should correctly parse type from PrimaryGeneratedColumn options
github issues > #7788 MongoDB update make changes only to first matched document
✔ should update all documents related to search pattern
github issues > #7809 MongoDB delete make changes only to first matched document
✔ should delete all documents related to search pattern
github issues > #7851 Updating (using save method) a ManyToOne relation sets the object.relation_id to null
✔ should update the message.user_id to the new value
github issues > #7852 saving a ManyToMany relation tries to insert (DEFAULT, entity2.id) instead of (entity1.id, entity2.id), when id is Buffer
✔ should insert (entity1.id, entity2.id)
github issues > #7867 Column not renamed when schema/database is set
schema is set
✔ should correctly change column name
database is set
✔ should correctly change column name (575ms)
github issues > #7882 .findOne reduces relations to an empty array
✔ should delete all documents related to search pattern
github issues > #7907 add support for mongodb driver v5
✔ should find the Post without throw error: Cannot read property 'prototype' of undefined
github issues > #7932 non-ascii characters assigned to var/char columns in SQL are truncated to one byte
✔ should store non-ascii characters in var/char without data loss
- should throw an error if characters in a string are too long to store
✔ should not change char or varchar column types to nchar or nvarchar
github issues > #7974 Adding relations option to findTrees()
✔ should return tree without sites relations
✔ should return tree with sites relations
github issues > #799 sqlite: 'database' path should be created
✔ should create the whole path to database file
✔ should create the whole path to database file for better-sqlite3
github issues > #80 repository.save fails when empty array is sent to the method
✔ should persist successfully and return persisted entity
✔ should not fail if empty array is given to persist method
github issues > #8011 Enum values with multiple apostrophes not properly escaped in MySQL
✔ should properly escape all apostrophes (129ms)
github issues > #8018 Non-unique relation property names causes entity mixup in query results
✔ should create child entities of the correct type
github issues > #8026 Inserting a value for a column that has a relation, and is also a date, results in the value being inserted as DEFAULT
✔ it should include a related date column in the constructed query
github issues > #807 Error in persisting dates
✔ should be able to save dates as objects
✔ should be able to save dates as strings
github issues > #8076 Add relation options to all tree queries (missing ones)
✔ should return tree without sites relations
✔ should return tree with sites relations
✔ should return roots without member relations
✔ should return roots with member relations
✔ should return descendants without member relations
✔ should return descendants with member relations
✔ should return descendants tree without member relations
✔ should return descendants tree with member relations
✔ should return ancestors without member relations
✔ should return ancestors with member relations
✔ should return ancestors tree without member relations
✔ should return ancestors tree with member relations
github issues > #813 order by must support functions
✔ should work perfectly
✔ should work perfectly with pagination as well
github issues > #815 @RelationId properties are not updated after entity saving
✔ should work perfectly with many-to-one relation
✔ should work perfectly with one-to-many relation
✔ should work perfectly with many-to-many relation
✔ should work perfectly with many-to-many relation (inverse side)
github issues > #8158 Typeorm creates migration that creates already existing unique constraint
✔ should recognize model changes
✔ should not generate queries when no model changes (680ms)
github issues > #8221
✔ afterLoad entity modifier must not make relation key matching fail
github issues > #8273 Adding @Generated('uuid') doesn't update column default in PostgreSQL
✔ should add DEFAULT value when @Generated('increment') is added
✔ should remove DEFAULT value when @Generated('increment') is removed
✔ should add DEFAULT value when @Generated('uuid') is added
✔ should remove DEFAULT value when @Generated('uuid') is removed
github issues > #8346 MySQL: Regression when using take, orderBy, and getMany on a joined relation
✔ should return customers ordered by contacts
github issues > #836 .save won't update entity when it contains OneToOne relationship
✔ should work perfectly
github issues > #8370 Add support for Postgres GENERATED ALWAYS AS IDENTITY
✔ should produce proper SQL for creating a column with `BY DEFAULT` identity column
github issues > #838 Time zones for timestamp columns are incorrectly fetched and persisted in PostgreSQL
- should return date & time stored in PostgreSQL database correctly
- should persist date & time to the PostgreSQL database correctly
github issues > #8393 When trying to update `update: false` column with `@UpdateDateColumn` the update column is updated
✔ should not update the @UpdateDateColumn column when trying to update un-updatable column
github issues > #8398 Separate update event into the update, soft remove and restore events
✔ should trigger different events for update, soft remove, and recover
persistence > delete orphans
when a Post is removed from a Category
✔ should retain a Post on the Category
✔ should mark orphaned Post as soft-deleted
✔ should retain foreign keys on remaining Posts
github issues > #8430 sqlite temporary tables do not honor withoutRowid
✔ should keep 'withoutRowid' after table recreation
github issues > #8443 QueryFailedError when tree entity with JoinColumn > closure-table
✔ categories should be attached via parent and saved properly
✔ categories should be attached via children and saved properly
✔ categories should be attached via children and saved properly and everything must be saved in cascades
- categories should remove removed children
- sub-category should be removed with all its children
✔ findTrees() tests > findTrees should load all category roots and attached children
✔ findTrees() tests > findTrees should load multiple category roots if they exist (38ms)
✔ findTrees() tests > findTrees should filter by depth if optionally provided
✔ findDescendantsTree() tests > findDescendantsTree should load all category descendents and nested children
✔ findDescendantsTree() tests > findDescendantsTree should filter by depth if optionally provided
github issues > #8443 QueryFailedError when tree entity with JoinColumn > materialized-path
✔ attach should work properly
✔ categories should be attached via children and saved properly
✔ categories should be attached via children and saved properly
✔ categories should be attached via children and saved properly and everything must be saved in cascades
✔ findTrees() tests > findTrees should load all category roots and attached children
✔ findTrees() testsfindTrees should load multiple category roots if they exist
✔ findTrees() testsfindTrees should filter by depth if optionally provided
✔ findDescendantsTree() tests > findDescendantsTree should load all category descendents and nested children
✔ findDescendantsTree should filter by depth if optionally provided
github issues > #8443 QueryFailedError when tree entity with JoinColumn > nested-set
✔ attach should work properly
✔ categories should be attached via children and saved properly
✔ categories should be attached via children and saved properly
✔ categories should be attached via children and saved properly and everything must be saved in cascades (42ms)
✔ findTrees() tests > findTrees should load all category roots and attached children
✔ findTrees() tests > findTrees should filter by depth if optionally provided
✔ findTrees() tests > findTrees should present a meaningful error message when used with multiple roots + nested sets
✔ findDescendantsTree() tests > findDescendantsTree should load all category descendents and nested children
✔ findDescendantsTree() tests > findDescendantsTree should filter by depth if optionally provided
github issues > #8444 entitySkipConstructor not working
without entitySkipConstructor
✔ createTestingConnections should fail with 'someColumn cannot be undefined.'
with entitySkipConstructor
✔ createTestingConnections should succeed (327ms)
github issues > #8459 Can not create indexes of materialized views
✔ should create a materialized view index at runtime
✔ should rename a materialized view unique index
✔ should delete a materialized view index
✔ should create a materialized view index
✔ should create a materialized view unique index
github issues > #8485 second migration is generated for a combination of PrimaryColumn and JoinColumn
✔ should not create second migration (2174ms)
github issues > #85 - Column option insert: false, update: false
✔ should ignore value of non-inserted column
✔ should be able to create an entity with column entirely missing (506ms)
github issues > #8522 Single table inheritance returns the same discriminator value error for unrelated tables where their parents extend from the same entity
Unrelated tables
✔ should loads internal user and internal role
Related tables
✔ Should throw error when related tables have the same discriminator
github issues > #8527 cannot clear database inside a transaction.
✔ should not fail when clearing a database inside a transaction (211ms)
github issues > #8556 TreeRepository.findDescendants/Tree should return empty if tree parent entity does not exist
✔ should load descendants when findDescendants is called for a tree entity
✔ should return empty when findDescendants is called for a non existing tree entity
github issues > #8627 junction aliases are not unique
✔ should not fail querying many-to-many-relation
github issues > #863 indices > create schema
build schema
✔ it should just work, creating the index (920ms)
github issues > #8644 BUG - Special keyword column name for simple-enum in sqlite
✔ it should be able to set special keyword as column name for simple-enum types
github issues > #867 result of `findAndCount` is wrong when apply `skip` and `take` option
✔ should work perfectly
github issues > #8681 DeepPartial simplification breaks the .create() and .save() method in certain cases.
✔ should .save() and .create() complex deep partial entities
✔ should .save() and .create() complex deep partial entities using a generic repository
github issues > #8690 Relations do not render primary key column values correctly when transformers present
✔ should load relations correctly when primary columns have transformers
github issues > #8723 Fail on Update when reference exists together with FK: multiple assignments to same column
✔ should able to update when both reference and the id exist in the update object
github issues > #8747 QueryBuilder update handles Date objects wrong on a ManyToOne relationship.
- should correctly update the datetime field
github issues > #8796 New find select object api should support false values as expected
✔ should suport false value when selecting fields
github issues > #8832 Add uuid, inet4, and inet6 types for mariadb
basic use of new maria db types
✔ should create table with uuid, inet4, and inet6 type set to column for relevant mariadb versions
regression test mysql uuid generation
✔ should create table with with varchar with length 36 when version is mysql
entity-metadata-validator
✔ should throw error if mariadb uuid is supported and length is provided to property
✔ should not throw error for mysql when uuid is provided and a length property is provided
github issues > #8890 it should be possible to query IS NULL on ManyToOne relations
✔ where IsNull
✔ where In
✔ where IsNull OR In
github issues > #8890 it should be possible to query IS NULL on OneToOne relations on owner side
✔ where IsNull
✔ where In
✔ where IsNull OR In
github issues > #8892 ManyToMany relations save throws "Violation of PRIMARY KEY constraint"
✔ should work perfectly with with many to many relation with primary key from related object is a primary key from an many to one relation (44ms)
github issues > #8936 DropIndex with a TableIndex without name is not working
✔ should drop the index as expected (1946ms)
query builder order nulls first/last
✔ should work with uppercase/lowercase first/last
cli init command
✔ should work with mysql option (22880ms)
✔ should work with mariadb option (14120ms)
✔ should work with postgres option (16130ms)
✔ should work with cockroachdb option (14110ms)
✔ should work with sqlite option (20415ms)
✔ should work with better-sqlite3 option (17478ms)
✔ should work with mssql option (21582ms)
✔ should work with mongodb option (15335ms)
github issues > #9033 Cannot manually insert type in discriminator column of parent entity class whenusing single table inheritance when creating instance of parent entity
✔ is possible to set the discriminator column manually on the base entity
github issues > #904 Using closure tables without @TreeLevelColumn will always fail on insert
✔ should work correctly when saving using parent category
✔ should work correctly when saving using children categories
✔ should be able to retrieve the whole tree
github issues > #9049 mongodb entities with 2 level-nested arrays throws an 'document[embedded.prefix].map is not a function' error
✔ should save entities properly
github issues > #9063 Support postgres column with varchar datatype and uuid_generate_v4() default
✔ it should be able to set special keyword as column name for simple-enum types
github issues > #9152 Can't use LessThan for Union field
✔ should not raise TypeScript error when LessThan with Union is passed to FindOptionsWhere
github issues > #9173 missing typeorm_metadata
✔ should create a view without view entity (446ms)
github issues > #9176 The names of foreign keys created by queryRunner.createForeignKey and schema:sync are different with SQLite
github issues > #9176 foreign keys
✔ should not generate queries when created foreign key with queryRunnner.createForeignKey
github issues > #9176 unique constraint
✔ should not generate queries when created unique constraint with queryRunnner.createUniqueConstraint
github issues > #9176 check constraint
✔ should not generate queries when created check constraint with queryRunnner.createCheckConstraint
github issues > #9189 check invalid constraint options
✔ should throw an exception, when invalid option is configured
github issues > #922 Support HSTORE column type
✔ should correctly implement HSTORE type
github issues > #9230 Incorrect date parsing for year 1-999
mixedDateToDateString
✔ should format a year less than 1000 with correct 0 padding
github issues > #9241 Incorrect insert order when cascade inserting parent inherited relations
✔ should save entities properly
github issues > #9266 queryRunner.getTable() fails if Foreign Key is set in target table
✔ should be able to load tables
github issues > #9272 Fix select on deeply nested embedded entities, using Repository API
✔ should be able to pass select options for deeply nested embedded entities
github issues > #929 sub-queries should set their own parameters on execution
✔ should persist successfully and return persisted entity
github issues > #9318 Change version query from SHOW server_version to SELECT version
✔ should have proper isGeneratedColumnsSupported value for postgres version
github issues > #9323 Add new VirtualColumn decorator feature
✔ should generate expected sub-select & select statement
✔ should generate expected sub-select & nested-subselect statement
✔ should not generate sub-select if column is not selected
✔ should be able to save and find sub-select data in the database
✔ should be able to save and find sub-select data in the databse (with query builder)
github issues > #9341 "bigNumberStrings:false" is not working for postgres
✔ should fetch big int as number not string when using parseInt8=true
github issues > #9379 RelationIdLoader is not respecting maxAliasLength
✔ should fetch related entities properly
github issues > #9381 The column option 《transformer》 affects the result of the query condition generation
✔ transform and find values (406ms)
✔ transform json values and find values
github issues > #9399 mssql: Column is dropped and recreated in every migration
✔ No migration should be created
github issues > #9405 Incorrect subject sorting with multi-inheritance entities
✔ should correctly sort entities with multi-inheritances
better-sqlite3 driver > enable wal
✔ github issues > #9410 The better-sqlite3 driver should support the enableWal flag
github issues > #9365
✔ should work with conflict path
github issues > #945 synchronization with multiple primary keys
✔ schema should include two primary keys
github issues > #9457 No changes in database schema were found, when simple-enum is changed.
✔ should drop and recreate 'CHECK' constraint to match enum values
github issues > #9477 Unsigned Integers Columns constantly dropped and recreated
✔ should not create migrations for unsigned indices
github issues > #948 EntityManager#save always considers a Postgres array-type field to have changed
✔ should not produce extra query when array is updated?
github issues > #9518 Can't pass ObjectLiteral in MongoRepository.find where condition due to typings
✔ should be able to use ObjectLiteral in find where condition
github issues > #953 MySQL 5.7 JSON column parse
✔ should retrieve record from mysql5.7 using driver mysql2
github issues > #9534 materialized-path
✔ attach should work properly (50ms)
✔ findTrees() tests > findTrees should load all category roots
github issues > #9601 view+schema+synchronize broken for oracle
✔ should recognize model changes
✔ should not generate queries when no model changes
github issues > #966 Inheritance in embeddables
✔ should save and load Superclass fields in embeddable
github issues > #9664 add JsonContains operator
✔ should find addresses in json field by name
github issues > #9673 TreeRepository not loading relations on findDescendants() method using QUERY method (relationLoadStrategy)
✔ should generate multiple queries per relation (42ms)
github issues > #9684 Incorrect enum default value when table name contains dash character
✔ should get default enum value
github issues > #9690 Incorrect SQL expression if `where` parameter is empty array
✔ should run without throw error
github issues > #970 Mongo Bad Sort Specification
✔ should order properly without errors
github issues > #9715 Database schema is not updated by sync/migration when 'simple-enum' is changed.
✔ should update 'CHECK' constraint to match enum values
github issues > #9770 check for referencing foreign keys when altering a table using sqlite
✔ shouldn't loose dependant table data
github issues > #9829 Incorrect default value with concat value of function
✔ should get default concat value
github issues > #9833 Add support for Single Table Inheritance when using Entity Schemas
✔ should instantiate concrete entities when using EntitySchema
github issues > #9885
✔ should be connected
github issues > #9895
✔ should allow find order on object property
github issues > #9903 json data type
json supported type for mariadb
✔ should create table with json constraint
github issues > #9948 Subscribers with both 'beforeUpdate' and 'afterUpdate' methods defined cause duplicate 'updatedColumn' entries
✔ should not duplicate update column
github issues > #996 already loaded via query builder relations should not be loaded again when they are lazily loaded
✔ should be able to find by object reference
github issues > #9960
✔ select + order by must work without issues
github issues > #9977
✔ where relations with (More|Less)ThanOrEqual operators (79ms)
github issues > #9984 TransactionRetryWithProtoRefreshError should be handled by TypeORM
✔ should retry transaction on 40001 error with 'inject_retry_errors_enabled=true'
✔ should retry transaction on 40001 error
github issues > #9988 RelationIdLoader reuses the same queryplanner within a transaction
✔ custom repository querybuilders within transactions returns relations for getOne() and getMany
insertion
✔ basic insert functionality
other issues > auto-increment id as string
✔ should relationIds exist
other issues > column with getter / setter should work
✔ getters and setters should work correctly
other issues > ekifox reported issue with increment
✔ getters and setters should work correctly
other issues > entity change in listeners should affect persistence
✔ if entity was changed in the listener, changed property should be updated in the db
other issues > entity change in subscribers should affect persistence
✔ if entity was changed, subscriber should be take updated columns (38ms)
other issues > escaping function parameter
✔ select query builder should ignore function-based parameters
✔ insert query builder should work with function parameters
✔ update query builder should work with function parameters
other issues > getId should not return undefined for composite primary keys with lazy relations
✔ getId should not return undefined
other issues > allow HSTORE column type to use transformers
✔ should use the transformer set in the column options
other issues > hydration performance
✔ if entity was changed in the listener, changed property should be updated in the db (3360ms)
other issues > double inheritance produces multiple duplicated columns
✔ should not produce duplicate columns
other issues > joining empty relations
✔ should return empty array if its joined and nothing was found
✔ should return empty array if its joined and nothing was found, but relations in empty results should be skipped
other issues > using limit in conjunction with order by
✔ should persist successfully and return persisted entity (771ms)
other issues > mongodb entity change in listeners should affect persistence
✔ if entity was changed in the listener, changed property should be updated in the db
✔ if entity was loaded in the listener, loaded property should be changed
other issues > mongodb entity change in subscribers should affect persistence
✔ if entity was changed, subscriber should be take updated columns
✔ if entity was loaded, loaded property should be changed
mssql -> add column to existing table
✔ should fail to add column
✔ should succeed to add column
other issues > using nested child entities
✔ should insert without error
other issues > preventing-injection
✔ should not allow selection of non-exist columns via FindOptions
✔ should throw error for non-exist columns in where expression via FindOptions
✔ should not allow selection of non-exist columns via FindOptions
✔ should not allow non-numeric values in skip and take via FindOptions
✔ should not allow non-numeric values in skip and take in QueryBuilder
✔ should not allow non-allowed values in order by in QueryBuilder
other issues > redundant cascade schema queries in many-to-many relation
✔ should work correctly
other issues > bulk save in sqlite
✔ should save entities in bulk
other issues > Relation decorators: allow to pass given table name string instead of typeFunction or entity name
✔ should work with one-to-one relations
✔ should work with many-to-one/one-to-many relations
✔ should work with many-to-many relations
other issues > using take with multiple primary keys
✔ should persist successfully and return persisted entity (883ms)
other issues > correctly compute change for transformed json / jsonb columns
✔ should not update entity if transformed JSON column did not change
✔ should not update entity if transformed JSONB column did not change
other issues > update relational column on relation change
✔ should update relational column when relation is inserted
path-utils
isAbsolute
✔ discriminates cross platform relative paths
toPortablePath
Platform darwin
toPortablePath
✔ should change paths on non-Windows platform
Platform win32
toPortablePath
✔ shouldn't change absolute posix paths when producing portable path
✔ shouldn't change absolute paths that are already portable
✔ should normalize the slashes in relative Windows paths
✔ should transform Windows paths into their posix counterparts (uppercase drive)
✔ should transform Windows paths into their posix counterparts (lowercase drive)
✔ should transform Windows paths into their posix counterparts (forward slashes)
✔ should support Windows paths that contain both backslashes and forward slashes
✔ should support drive: Windows paths
✔ should support UNC Windows paths (\\[server]\[sharename]\)
✔ should support Long UNC Windows paths (\\?\[server]\[sharename]\)
✔ should support Long UNC Windows paths (\\?\UNC\[server]\[sharename]\)
✔ should support Long UNC Windows paths (\\?\[drive_spec]:\)
✔ should support Long UNC Windows paths with dot (\\.\[physical_device]\)
2030 passing (51m)
166 pending
typeorm-0.3.17 end
[Pipeline] }
Cache not saved (ws/jenkins-pingcap-tidb-merged_integration_nodejs_test-1070/tidb-test already exists)
[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] }
[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
Finished: SUCCESS