Mathieu DARTIGUES
f3c73ccd58
Add new option for seed : recursive ( #3974 )
2020-08-10 15:10:37 +02:00
Harish Karumuthil
8ba73e568a
Escape single quoted values passed to defaultTo function ( #3899 )
2020-08-08 20:48:45 +03:00
issa marie tseng
378ae79641
Ensure DB stream is destroyed when the PassThrough is destroyed ( #2324 ). ( #3900 )
2020-08-08 20:27:47 +03:00
cubikrichard
6203b59076
support postProcessResponse for streams ( #3870 ) ( #3931 )
2020-08-08 17:57:58 +03:00
Mr D
cfce685775
ESM module interop fails if calling module/package is of type 'module' #3937 ( #3938 )
2020-08-08 17:39:57 +03:00
Mathieu DARTIGUES
ab7644425d
Support multiple directories for seeds ( #3967 )
2020-08-08 15:21:43 +03:00
Casey Foster
3677e547a9
Fix migration source name in rollback all ( #3956 )
2020-08-07 18:53:59 +03:00
Keno Medenbach
2bd2ecd91c
MSSQL: Added the removal of a columns default constraint, before dropping the column ( #3855 )
2020-05-15 11:28:34 +02:00
Igor Savin
c0afe14cde
Warn user if custom migration source is being reset ( #3839 )
2020-05-06 00:13:09 +02:00
Igor Savin
38f54ce8f0
Refactor migration logic to use async/await. Add test case for using classes with custom migration sources ( #3838 )
2020-05-05 19:10:50 +02:00
Igor Savin
40621fac9e
Update dependencies ( #3830 )
2020-04-26 19:35:06 +02:00
Zach McElrath
b626702b47
Add migrate:unlock command, truncate on forceFreeMigrationsLock ( #3822 )
2020-04-23 21:51:32 +02:00
Lorefnon
7b4d208bae
Fix inferrence of seed/migration extension from knexfile extension ( #3814 )
...
Current implementation doesn't work when knexfile has multiple env-specific configuration sections.
Resolves #3807
2020-04-20 01:19:15 +02:00
Igor Savin
e37aeaa31c
Prepare for 0.21.0 release ( #3811 )
2020-04-19 00:40:23 +02:00
Brian Lauber
8d5715a03a
Fix: Support for .finally(..) on knex's Promise-alikes ( #3800 )
2020-04-15 21:05:40 +02:00
Edvaldo Szymonek
336b41e148
Add clearGroup method ( #3771 )
2020-04-13 01:09:51 +02:00
Igor Savin
7568ab51c4
Split tests in groups ( #3785 )
2020-04-07 21:27:40 +02:00
Florent Vilmart
41d02ba5c1
CLI: adds support for asynchronous knexfile loading ( #3748 )
2020-03-24 17:07:05 +01:00
Kabir Baidhya
a6551559f0
Minor improvements on the usage of fs utilities - unify all the fs functions into the same util/fs to simplify things ( #3749 )
2020-03-24 15:50:47 +01:00
Kabir Baidhya
ec2351b7a8
Minor test internal enhancements ( #3747 )
2020-03-23 22:09:01 +01:00
Kabir Baidhya
078b749892
Add unit tests for escape utility functions ( #3742 )
2020-03-22 18:44:51 +01:00
Kabir Baidhya
a7031c3cef
Upgrade package mkdirp and improve it's usage ( #3741 )
2020-03-21 11:01:10 +01:00
Florent Vilmart
998c92ca97
Typescript: Makes the ChainableInterface conform to Promise<T> ( #3724 )
2020-03-19 23:19:57 +01:00
Brian Lauber
31c5b86ec4
Fix: Transaction_OracleDB can use config.connection ( #3731 )
2020-03-15 20:30:40 +01:00
Brian Lauber
37d9c30347
Fix/method binding on knex proxy ( #3717 )
...
* knex methods are proxies for context methods ...
... as opposed to injecting the methods directly onto the knex
function. (Which was then causing `this` to point to the wrong
object when evaluating the context methods)
* Moved CONTEXT_METHODS constant to a higher scope
* mv knex.context -> this.context
* Extracted KNEX_PROPERTY_DEFINITIONS to module scope ...
... which was possible since all of the properties reference
`this` instead of `knex` now
* shallowCloneFunction no longer accesses _context ...
... instead, it uses the normal context property
* transaction method delegates to _transaction ...
... This way, we can be sure that the lower-level details are
consistent across implementations. Individual implementations
just need to handle the quirks around setting up the `config`
and `outerTx`
* CONTEXT_METHODS shared. Fixed override of withUserParams ...
Restructured the code so that CONTEXT_METHODS populates the
KNEX_PROPERTY_DEFINITIONS with the proxy methods.
In doing so, it also exposed the fact that the withUserParams(..)
method was being overridden on the Transactor instead of its
context. So, that bug was fixed as well.
* Added a TODO to remove client.makeKnex(..) in future PR
* Added a warning about QueryBuilder.extend(..) and side-effects
2020-03-11 16:05:03 -04:00
Brian Lauber
0f523db957
Removed .should(..) syntax from test cases ( #3713 )
2020-03-09 10:10:33 -04:00
Brian Lauber
9d07bc97ea
Removed some globals from tests ( #3712 )
...
* `chai` is no longer global
* sinon is no longer globally defined
* expect(..) is no longer defined globally
* Removed obsolete eslint hints about globals
* Removed unused variable ( `expect(..)` )
2020-03-08 19:48:23 -04:00
Brian Lauber
d00bd8d2dd
Fix: Added missing call to _reject in Transactor#transaction ( #3706 )
2020-03-07 01:53:33 +01:00
Brian Lauber
4006bddbcf
Fixed a few unhandled Promise rejections in a test case ( #3705 )
2020-03-06 22:26:34 +01:00
Brian Lauber
1ae9312fa4
Updated .gitignore files to ignore testing artifacts ( #3709 )
2020-03-06 22:24:24 +01:00
Igor Savin
b80966a60e
Cleanup/extract transaction ordering logic (implementation 2.0) ( #3698 )
2020-03-05 21:40:33 +01:00
Brian Lauber
05fedd9e11
Mark missing test cases as "pending" rather than "passed" ( #3695 )
...
* Missing test cases are marked as "pending" rather than "passed"
* Work-around for connection disposal bug in pooling logic...
See this conversation thread for more info: https://github.com/knex/knex/issues/3636#issuecomment-592005391
2020-03-02 01:04:01 +01:00
maximelkin
dc30abf39e
bugfix mysql query errors ignored ( #3690 )
2020-02-29 00:16:07 +01:00
lando-cal
3bea3f66ec
Add OracleDB handling for buffer type in fetchAsString ( #3685 )
...
As released in [2.3.0](https://github.com/oracle/node-oracledb/blob/master/CHANGELOG.md#node-oracledb-v230-7-jun-2018 ) of node-oracledb, this adds handling to fetchAsString for the `BUFFER` type, allowing fetchAsString to interpret `RAW` fields.
2020-02-25 01:27:33 +01:00
maximelkin
8159f04c12
Remove dependency on bluebird methods from tests ( #3682 )
...
* Remove dependency on bluebird methods from tests
* Introduce `"chai-as-promised"` plugin
* Minor enhancements to the testing logic
2020-02-24 19:24:30 -05:00
Jake Coffman
d50d00644c
oracledb: commit was a no-op causing race conditions ( #3668 )
...
The underlying issue was that query *always* committed, even during a transaction. The previous fix was to just disable commitAsync in a transaction but then that also disabled explicit commit calls. Instead, this fix disables query's commits during transactions so that explicit commits still work.
2020-02-16 20:26:13 +01:00
Brian Lauber
2c206a8fec
Fix: Knex CLI calls process.chdir() before opening Knexfile ( #3661 )
2020-02-13 08:58:33 +01:00
maximelkin
88d832cd36
replace Bluebird.timeout ( #3634 )
2020-02-12 21:42:15 +01:00
Brian Lauber
947273e24a
Improve Support for Liftoff's Preloaders ( #3613 )
2020-02-08 17:23:44 +01:00
Igor Savin
c14252d907
Refactor more tests to use cli-testlab ( #3640 )
2020-01-28 02:28:40 +01:00
Mr D
65086025c0
#3751 : Esm interop flag ( #3616 )
2020-01-14 21:01:31 +01:00
yeonhoyoon
4a2fa3b6c9
Print help only when there are no arguments ( #3617 )
2020-01-14 20:58:28 +01:00
Jake Coffman
22558209d4
dispose Oracle connection on connection error ( #3611 )
...
Co-authored-by: abskmj <abskmj@gmail.com>
2020-01-05 18:47:32 +01:00
Igor Savin
80a2516734
Throw better error when trying to modify schema while using unsupported dialect ( #3609 )
2020-01-05 00:04:41 +01:00
Kabir Baidhya
2800e72d2f
Add tests for some of the string utility functions ( #3568 )
2020-01-04 22:59:41 +01:00
Jake Coffman
07997279b7
fix #3605 not releasing connection from pool on disconnect ( #3606 )
2020-01-04 22:56:14 +01:00
Igor Savin
4feefdf3d2
Enforce Unix (lf) line terminators ( #3598 )
2019-12-29 20:28:40 +01:00
Igor Savin
9b37c9480b
Return more information about empty updates ( #3597 )
2019-12-28 22:36:14 +01:00
Ahmed Ashour
a613fe23df
Fix some spelling mistakes ( #3572 )
2019-12-10 22:53:05 +01:00
MaliaGuerrero
03d6f063d5
Initialize data to buffer instead of string for non-strings ( #3545 )
2019-11-21 19:46:45 +01:00