UNPKG

typeorm-test-transactions

Version:

A transactional wrapper for tests that use TypeORM that automatically rolls back the transaction at the end of the test.

204 lines (101 loc) 11.5 kB
# Changelog All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines. ### [3.6.1](https://github.com/entrostat/typeorm-test-transactions/compare/v3.6.0...v3.6.1) (2021-09-26) ### Bug Fixes * **changelog:** Removed the useless entries in the changelog after fixing entro-version ([2bfce8a](https://github.com/entrostat/typeorm-test-transactions/commit/2bfce8aeae302ce3b4ac9eb1cf3fcf81c0c8d4c6)) ## [3.6.0](https://github.com/entrostat/typeorm-test-transactions/compare/v3.0.0...v3.6.0) (2021-09-26) ### Features * **build:** The build is working correctly, using entro-version to run a release ([0a6b0c2](https://github.com/entrostat/typeorm-test-transactions/commit/0a6b0c2e410bb2847edffe70c64654b9fd7b3b28)) * **versioning:** Added entro-version to the project ([e5fd464](https://github.com/entrostat/typeorm-test-transactions/commit/e5fd4646b4a0d057ccb363e5f85c873d5ef94606)) ### Bug Fixes * **build:** Don't checkout master before publishing because of entro-version ([34f1c6a](https://github.com/entrostat/typeorm-test-transactions/commit/34f1c6a6418d4e7eed2b75f20fc71d4d2ee5c6b2)) * **keywords:** Added typescript to the keywords ([7316cf3](https://github.com/entrostat/typeorm-test-transactions/commit/7316cf3e09229dcfc21faebc5dfd6e327a2eee40)) ## [3.0.0](https://github.com/entrostat/typeorm-test-transactions/compare/v2.0.0...v3.0.0) (2021-09-18) ### Features * **nested-transactions:** Added the ability to support multiple connections ([97f8058](https://github.com/entrostat/typeorm-test-transactions/commit/97f8058a98a91b8a834490d38662d95d983ad6c1)), closes [#25](https://github.com/entrostat/typeorm-test-transactions/issues/25) ### Bug Fixes * **formatting:** Changed the formatting and naming of functions to ensure that it's more readable ([24d4075](https://github.com/entrostat/typeorm-test-transactions/commit/24d40750aa7de7b4c10807b819d8b81c1679557a)) ## [1.4.0](https://github.com/entrostat/typeorm-test-transactions/compare/v1.3.0...v1.4.0) (2019-12-15) ## [1.3.0](https://github.com/entrostat/typeorm-test-transactions/compare/v1.2.3...v1.3.0) (2019-11-27) ## [2.0.0](https://github.com/entrostat/typeorm-test-transactions/compare/v1.14.3...v2.0.0) (2021-09-18) ### [1.14.3](https://github.com/entrostat/typeorm-test-transactions/compare/v1.14.2...v1.14.3) (2021-09-18) ### Bug Fixes * **devops:** Added a Github action to test Postgres 9 ([770e1f7](https://github.com/entrostat/typeorm-test-transactions/commit/770e1f7126008d9283581a5b7c72276a4d46d1c5)) * **devops:** Removed Travis-CI and plug into the Github Actions for testing ([4474296](https://github.com/entrostat/typeorm-test-transactions/commit/4474296ce6c7e18baf88a2682922c6e216ccae6c)) ### [1.14.2](https://github.com/entrostat/typeorm-test-transactions/compare/v1.14.1...v1.14.2) (2021-01-02) ### [1.14.1](https://github.com/entrostat/typeorm-test-transactions/compare/v1.14.0...v1.14.1) (2020-10-31) ## [1.14.0](https://github.com/entrostat/typeorm-test-transactions/compare/v1.13.0...v1.14.0) (2020-10-31) ### Features * **tests:** fixed major bugs on the tests ([1fe86f6](https://github.com/entrostat/typeorm-test-transactions/commit/1fe86f67d79955eb2712d446a9551f9d606f7ad8)) ## [1.13.0](https://github.com/entrostat/typeorm-test-transactions/compare/v1.12.1...v1.13.0) (2020-08-22) ### Features * **testing:** added tests for Postgres 13 ([62eb9e2](https://github.com/entrostat/typeorm-test-transactions/commit/62eb9e21925124f65ceca4b8c5200e4ebbdb61d1)), closes [#17](https://github.com/entrostat/typeorm-test-transactions/issues/17) ### [1.12.1](https://github.com/entrostat/typeorm-test-transactions/compare/v1.12.0...v1.12.1) (2020-08-22) ## [1.12.0](https://github.com/entrostat/typeorm-test-transactions/compare/v1.11.1...v1.12.0) (2020-08-22) ### Features * **testing:** added tests for mariadb 10 ([ffd3475](https://github.com/entrostat/typeorm-test-transactions/commit/ffd347558d1945fb37d0b2d6515cd1928121e69a)), closes [#15](https://github.com/entrostat/typeorm-test-transactions/issues/15) ### [1.11.1](https://github.com/entrostat/typeorm-test-transactions/compare/v1.11.0...v1.11.1) (2020-05-27) ### Bug Fixes * **deps:** updated npm packages ([ff1ef77](https://github.com/entrostat/typeorm-test-transactions/commit/ff1ef778d55abf09245fb193c1797e0ebe430978)), closes [#12](https://github.com/entrostat/typeorm-test-transactions/issues/12) ## [1.11.0](https://github.com/entrostat/typeorm-test-transactions/compare/v1.10.1...v1.11.0) (2020-05-27) ### Features - **testing:** added mysql 8 tests ([420223c](https://github.com/entrostat/typeorm-test-transactions/commit/420223c25e652daaef22d1dfadb31a790ebfa6d9)), closes [#11](https://github.com/entrostat/typeorm-test-transactions/issues/11) ### [1.10.1](https://github.com/entrostat/typeorm-test-transactions/compare/v1.10.0...v1.10.1) (2020-03-24) ## [1.10.0](https://github.com/entrostat/typeorm-test-transactions/compare/v1.9.1...v1.10.0) (2020-03-05) ### Features - **testing:** added a second test file to test any init problems ([181f542](https://github.com/entrostat/typeorm-test-transactions/commit/181f542d94d942fc644818120e41dfdb45d199ad)), closes [#8](https://github.com/entrostat/typeorm-test-transactions/issues/8) ### [1.9.1](https://github.com/entrostat/typeorm-test-transactions/compare/v1.9.0...v1.9.1) (2020-03-05) ### Bug Fixes - **testing:** I wasn't importing the initialise function (which I was doing in the docs) ([517f54d](https://github.com/entrostat/typeorm-test-transactions/commit/517f54df57136d511369a2fbc36d916b1cabcd67)) ## [1.9.0](https://github.com/entrostat/typeorm-test-transactions/compare/v1.8.1...v1.9.0) (2019-12-15) ### Features - **testing:** added tests for mysql 5.7 ([5d10190](https://github.com/entrostat/typeorm-test-transactions/commit/5d10190bf28f7b7534ea19c4861547bb8eec237b)) ### [1.8.1](https://github.com/entrostat/typeorm-test-transactions/compare/v1.8.0...v1.8.1) (2019-12-15) ### Bug Fixes - **formatting:** ran prettier on code ([8b5dc71](https://github.com/entrostat/typeorm-test-transactions/commit/8b5dc7165c80214fa9bdacce163395a475f465db)) ## [1.8.0](https://github.com/entrostat/typeorm-test-transactions/compare/v1.7.1...v1.8.0) (2019-12-15) ### Features - **testing:** added testing for postgres 9 ([ab09273](https://github.com/entrostat/typeorm-test-transactions/commit/ab09273d2c41b19b08943fa87337345660e7edb9)) - **testing:** added tests for postgres 10 ([d14baef](https://github.com/entrostat/typeorm-test-transactions/commit/d14baefda4e60d396e09ae821cb7283f4293883b)) ### [1.7.1](https://github.com/entrostat/typeorm-test-transactions/compare/v1.7.0...v1.7.1) (2019-12-15) ### Bug Fixes - **build:** exclude tests from tsc build ([5271325](https://github.com/entrostat/typeorm-test-transactions/commit/52713256bf037ce81f5fb65853e8a444789504a4)) ## [1.7.0](https://github.com/entrostat/typeorm-test-transactions/compare/v1.6.0...v1.7.0) (2019-12-15) ### Features - **testing:** added postgres 12 tests ([05f8ea4](https://github.com/entrostat/typeorm-test-transactions/commit/05f8ea4880d59d2e3993c8d16831ba12e81f33ef)) ## [1.6.0](https://github.com/entrostat/typeorm-test-transactions/compare/v1.5.0...v1.6.0) (2019-12-15) ### Features - **testing:** added travis-ci testing to the project so that we can test different databases ([4874a76](https://github.com/entrostat/typeorm-test-transactions/commit/4874a761922e50b62c8013c04a63eae20a708048)) ## [1.5.0](https://github.com/entrostat/typeorm-test-transactions/compare/v1.2.3...v1.5.0) (2019-12-15) ### Features - divide error case to support test that used the supertest module ([b5319e1](https://github.com/entrostat/typeorm-test-transactions/commit/b5319e14d9e635b8607f45f26639f2294d424b3d)) ### Bug Fixes - **convention:** named the files to fit convention ([ab76b7d](https://github.com/entrostat/typeorm-test-transactions/commit/ab76b7dd976d78ab0864c3f20dd9760d01dca78f)) - **convetion:** named the files to fit convention ([d2c8d43](https://github.com/entrostat/typeorm-test-transactions/commit/d2c8d4357460430764d0358bdd2f81c17bf16890)) - **exception:** only catch certain exceptions in the transaction wrapper so that other exceptions are not caught ([3f756df](https://github.com/entrostat/typeorm-test-transactions/commit/3f756dfb27ec180556aa94810e969a48e24c17a7)) - **semver:** let the standard version package tag releases ([ccd4b5b](https://github.com/entrostat/typeorm-test-transactions/commit/ccd4b5bfa70b63e32e5e6255a4a592f058f32b0d)) ## [1.4.0](https://github.com/entrostat/typeorm-test-transactions/compare/v1.2.3...v1.4.0) (2019-12-15) ### Features - divide error case to support test that used the supertest module ([b5319e1](https://github.com/entrostat/typeorm-test-transactions/commit/b5319e14d9e635b8607f45f26639f2294d424b3d)) ### Bug Fixes - **convention:** named the files to fit convention ([ab76b7d](https://github.com/entrostat/typeorm-test-transactions/commit/ab76b7dd976d78ab0864c3f20dd9760d01dca78f)) - **convetion:** named the files to fit convention ([d2c8d43](https://github.com/entrostat/typeorm-test-transactions/commit/d2c8d4357460430764d0358bdd2f81c17bf16890)) - **exception:** only catch certain exceptions in the transaction wrapper so that other exceptions are not caught ([3f756df](https://github.com/entrostat/typeorm-test-transactions/commit/3f756dfb27ec180556aa94810e969a48e24c17a7)) ## [1.3.0](https://github.com/entrostat/typeorm-test-transactions/compare/v1.2.3...v1.3.0) (2019-11-27) ### Features - divide error case to support test that used the supertest module ([b5319e1](https://github.com/entrostat/typeorm-test-transactions/commit/b5319e14d9e635b8607f45f26639f2294d424b3d)) ### Bug Fixes - **exception:** only catch certain exceptions in the transaction wrapper so that other exceptions are not caught ([3f756df](https://github.com/entrostat/typeorm-test-transactions/commit/3f756dfb27ec180556aa94810e969a48e24c17a7)) ### [1.2.3](https://github.com/entrostat/typeorm-test-transactions/compare/v1.2.1...v1.2.3) (2019-10-12) ### Bug Fixes - **exports:** aliased the functions so they use the same code ([9fe43a6](https://github.com/entrostat/typeorm-test-transactions/commit/9fe43a648c3a0c57899d32a76fb7c7f5d9581018)) ### [1.2.2](https://github.com/entrostat/typeorm-test-transactions/compare/v1.2.1...v1.2.2) (2019-10-12) ### Bug Fixes - **exports:** aliased the functions so they use the same code ([9fe43a6](https://github.com/entrostat/typeorm-test-transactions/commit/9fe43a648c3a0c57899d32a76fb7c7f5d9581018)) ### [1.2.1](https://github.com/entrostat/typeorm-test-transactions/compare/v1.2.0...v1.2.1) (2019-10-12) ### Bug Fixes - **semver:** don't tag the commits with standard versioning (I use git flow) ([1ef2a9e](https://github.com/entrostat/typeorm-test-transactions/commit/1ef2a9ecb11b6e6d3ef25351cb64500f0f97ebf3)) ## [1.2.0](https://github.com/entrostat/typeorm-test-transactions/compare/v1.1.3...v1.2.0) (2019-10-12) ### Features - **semver:** added the changelog file ([d0713a5](https://github.com/entrostat/typeorm-test-transactions/commit/d0713a5af96163133d28802d05b60451b4d08338)) - **semver:** added the standard versioning library ([fb656a2](https://github.com/entrostat/typeorm-test-transactions/commit/fb656a29e665105ce35c8051e00994ad0faa3fcc))