Commit Graph

23 Commits

Author SHA1 Message Date
Manuel Trezza
1593575a87 build: release 2022-03-18 15:17:12 +01:00
Corey
a43638f300 test: improve transaction tests to use async/await (#7759) 2022-01-04 00:49:43 +01:00
Diamond Lewis
1666c3e382 [WIP] Enable test suite to be randomized (#7265)
* initial run

* Update ParseGraphQLServer.spec.js

* temporarily enable reporter

* Bump retry limit

* fix undefined database

* try to catch error

* Handle LiveQueryServers

* Update Config.js

* fast-fail false

* Remove usage of AppCache

* oops

* Update contributing guide

* enable debugger, try network retry attempt 1

* Fix ldap unbinding

* move non specs to support

* add missing mock adapter

* fix Parse.Push

* RestController should match batch.spec.js

* Remove request attempt limit

* handle index.spec.js

* Update CHANGELOG.md

* Handle error: tuple concurrently updated

* test transactions

* Clear RedisCache after every test

* LoggerController.spec.js

* Update schemas.spec.js

* finally fix transactions

* fix geopoint deadlock

* transaction with clean database

* batch.spec.js
2021-03-15 02:04:09 -05:00
Diamond Lewis
9563793303 Allow single server instance in test suite (#7262)
* initial pass

* reconfigureServer when needed

* finish postgres tests

* mongo tests

* more tests

* clean up

* re-add skipped test

* Fix transaction tests

* handle batch

* AuthenticationAdapter fix

* More reconfiguration

* clean up

* properly terminate cli servers

* handle Parse.Push

* Flaky PushController

* ensure reconfigureServer when changed

* fix postgres tests

* remove console.log

* LiveQuery spec remove duplicates and listeners
2021-03-13 09:05:22 -06:00
Diamond Lewis
39fa17f914 Postgres: Properly initialize database on startup and debugger (#7255)
* PG: Properly initialize database

* fix flaky tests

* flaky test

* correct test

* no idea

* clean up debugger
2021-03-10 11:31:35 -08:00
Antonio Davi Macedo Coelho de Castro
a430d6f7b7 Fix flaky test with transactions (#7187)
* Fix flaky test with transactions

* Add CHANGELOG entry

* Fix the other transactions related tests that became flaky because now Parse Server tries to submit the transaction multilpe times in the case of TransientError

* Remove fit from tests
2021-02-18 10:18:54 -08:00
Diamond Lewis
e6ac3b6932 fix(prettier): Properly handle lint-stage files (#6970)
Now handles top level files and recursive files in folders.

Set max line length to be 100
2020-10-25 15:06:58 -05:00
Diamond Lewis
e89cf25bc2 fix(directAccess): Properly handle response status (#6966)
* fix(directAccess): Properly handle response status

* clean up

* handle status in batch
2020-10-25 12:34:50 -05:00
Diamond Lewis
1246c90e91 fix(directAccess/cloud-code): Pass installationId with LogIn (#6903)
InstallationId didn't get passed correctly. Resulting in _Session without installationId

https://github.com/parse-community/parse-server/blob/master/src/Routers/UsersRouter.js#L263

* Fixed error with POST /login and req.query is undefined
2020-09-17 11:53:02 -05:00
Manuel
114d78e80a enabled MongoDB transaction test for MongoDB >= 4.0.4 (#6827) 2020-07-25 10:11:10 -07:00
Omair Vaiyani
85ec22ce3b fix(direct-access): save context not present if direct access enabled (#6764)
* fix(direct-access): save context not present if direct access enabled

[Open discussion](https://github.com/parse-community/parse-server/issues/6459) for feature with other issues

* only send context when present

* use object spread

* revert and add test

* rename test

Co-authored-by: dplewis <findlewis@gmail.com>
2020-07-16 22:56:47 -05:00
Antonio Davi Macedo Coelho de Castro
14a8d333a3 FIX: Transaction was aborting before all promises have either resolved or rejected (#5878) 2019-07-31 18:34:49 -07:00
Antonio Davi Macedo Coelho de Castro
8b97c1380b Batch transaction (#5849)
* Batch transaction boilerplate

* Refactoring transaction boilerplate

* Independent sessions test

* Transactions - partial

* Missing only one test

* All tests passing for mongo db

* Tests on Travis

* Transactions on postgres

* Fix travis to restart mongodb

* Remove mongodb service and keep only mongodb runner

* MongoDB service back

* Initialize replicaset

* Remove mongodb runner again

* Again only with mongodb-runner and removing cache

* Trying with pretest and posttest

* WiredTiger

* Pretest and posttest again

* Removing inexistent scripts

* wiredTiger

* One more attempt

* Trying another way to run mongodb-runner

* Fixing tests

* Include batch transaction on direct access

* Add tests to direct access
2019-07-31 02:41:07 -07:00
Florent Vilmart
d83a0b6808 Use Prettier JS (#5017)
* Adds prettier

* Run lint before tests
2018-09-01 13:58:06 -04:00
Florent Vilmart
ff25ae254d Update parse SDK to 2.0.0 (#4925)
* WIP: Integrate JS SDK v2

- Removes backbone style callbacks
- Use Promise instead of Parse.Promise

* Fixes ParseObject and ParseRelation

* Updates Parse.Query with promises

* Alls tests should pass

* Ensure a fresh user is used for each test

* Use REST implementation to avoid side effects for username/email duplicates

* Uses js sdk v2
2018-08-05 13:58:07 -04:00
Florent Vilmart
ae1a8226d5 Removes need to use babel-register (#4865)
* Removes need to use babel-register

- Adds watch to watch changes when running the test to regenerate
- Tests are now pure node 8

* Adds timing to helper.js

* Update contribution guide

* Adds inline sourcemaps generation to restore coverage

* nits
2018-07-02 23:30:14 -04:00
Florent Vilmart
17a2d269ef Always clear sessions when user password is updated (#3821)
* Adds repro to  issue #3289

* Always clear sessions when password is updated
2017-05-16 11:13:09 -07:00
Wissam Abirached
2533a8cdb3 Do not create user if username or password is empty (#3650) 2017-03-17 18:57:21 -04:00
Arthur Cinader
ca286b7108 Enable prefer-const lint rule (#3202) 2016-12-07 18:17:05 -05:00
Florent Vilmart
a9067260fc adds ability to pass custom installationId to create sessions in cloud code (#3156) 2016-12-06 16:46:09 -05:00
Arthur Cinader
37daafc7b0 Add strip whitespace and trailing eol to spec too. (#3159) 2016-12-01 21:45:49 -05:00
Florent Vilmart
8c2c76dd26 Adds liniting into the workflow (#3082)
* initial linting of src

* fix indent to 2 spaces

* Removes unnecessary rules

* ignore spec folder for now

* Spec linting

* Fix spec indent

* nits

* nits

* no no-empty rule
2016-11-24 15:47:41 -05:00
Florent Vilmart
cb7b54941b Direct Access to parse-server (#2316)
* Adds ParseServerRESTController experimental support

* Adds basic tests

* Do not create sessionToken when requests come from cloudCode #1495
2016-09-09 15:18:37 -04:00