Commit Graph

294 Commits

Author SHA1 Message Date
Florent Vilmart
3837d33ee4 Merge pull request #1066 from ParsePlatform/flovilmart.returnsFullModificationsForREST
Improvements in REST calls
2016-03-17 08:16:18 -04:00
Florent Vilmart
e270964b4b adds test for issue #1031 2016-03-17 00:04:52 -04:00
Florent Vilmart
e1c475512c Returns updated keys when running with beforeSave 2016-03-16 23:48:52 -04:00
Florent Vilmart
0f7335b534 Merge pull request #892 from ParsePlatform/flovilmart.httpRequestDefaultContentType
Default body to querystring, null encoding
2016-03-16 22:43:41 -04:00
Florent Vilmart
ba545fbf59 Returns full modifications on PUT 2016-03-16 22:30:52 -04:00
Florent Vilmart
461ddcbd05 Makes sure the location in results has the proper objectId 2016-03-16 20:37:59 -04:00
Florent Vilmart
3451fc3430 fixes same bug affecting $select and $dontSelect 2016-03-15 19:13:40 -04:00
Florent Vilmart
3ed3982e0e Fixes bug affecting matchesQuery and doesNotMatchQuery on relations on unfetched objects 2016-03-15 16:20:32 -04:00
Florent Vilmart
e00112ec3c adds failing test for resolution 2016-03-15 15:19:41 -04:00
Florent Vilmart
cadd6fe406 Sanitizes RestWrite.data before passing to inflated object 2016-03-11 23:03:47 -05:00
Florent Vilmart
b89619b6ee Full query support for badge Increment 2016-03-11 16:23:58 -05:00
Florent Vilmart
7d787328c5 Merge pull request #952 from ParsePlatform/flovilmart.OAuthImprovements
AuthData logic refactor
2016-03-11 15:38:19 -05:00
Florent Vilmart
daad05a00f removes key transformation for authData from restWrite, ensures authData is set in hooks 2016-03-11 15:14:53 -05:00
Florent Vilmart
2c991a4726 Merge pull request #956 from supersolid/steven.dboptions
Add database options to ParseServer constructor and pass to MongoStorageAdapter
2016-03-11 12:39:30 -05:00
steven-supersolid
6e65a8fc6f Add test for options being passed to MongoAdapter from DatabaseAdapter 2016-03-11 17:08:39 +00:00
Florent Vilmart
1ed868b99c Fixes #935, cleans up authData null keys on login for android crash 2016-03-11 11:14:58 -05:00
Florent Vilmart
bcffcbade2 Fix when multiple authData keys are passed 2016-03-11 09:02:21 -05:00
Mengyan Wang
d42d359437 Merge pull request #959 from ParsePlatform/wangmengyan.do_master_query_for_before/afterHook
Do master query for before/afterSaveHook
2016-03-10 22:47:04 -08:00
wangmengyan95
8ea2b615a4 Do master query for before/afterSaveHook 2016-03-10 22:38:07 -08:00
Florent Vilmart
1e7e4fe372 Merge pull request #898 from ParsePlatform/flovilmart.CLPAPI
Adds CLP API to Schema router
2016-03-11 00:32:41 -05:00
Florent Vilmart
c935ed8364 Always return default public permissions 2016-03-10 23:01:45 -05:00
Florent Vilmart
16e3529c96 Removes blacklisting, *-but test case 2016-03-10 19:20:05 -05:00
Florent Vilmart
9c5f14981e Renames oauth to authDataManager in src 2016-03-10 18:14:56 -05:00
Florent Vilmart
54d154f7aa Centralizes AuthData validation 2016-03-10 18:14:56 -05:00
Florent Vilmart
b1d399bf80 Adds blacklist permission, more test scenarios 2016-03-10 18:02:29 -05:00
Florent Vilmart
d71a58c217 Adds tests, improve coverage, adds ability to delete CLP with classLevelPermissions: null 2016-03-10 11:31:37 -05:00
Aneesh Devasthale
b47c927377 Changed FileLoggerAdapterSpec to fail gracefully on Windows
Running tests on Windows caused this error:
```
B:\Projects\Parse Server\parse-server\spec\FileLoggerAdapter.spec.js:38
        expect(results[0].message).toEqual('testing info logs');
                         ^

TypeError: Cannot read property 'message' of undefined
    at B:\Projects\Parse Server\parse-server\spec\FileLoggerAdapter.spec.js:38:26
    at ParsePromise.<anonymous> (B:\Projects\Parse Server\parse-server\src\Adapters\Logger\FileLoggerAdapter.js:9:17440)
    at ParsePromise.wrappedResolvedCallback (B:\Projects\Parse Server\parse-server\node_modules\parse\lib\node\ParsePromise.js:139:41)
    at ParsePromise.resolve (B:\Projects\Parse Server\parse-server\node_modules\parse\lib\node\ParsePromise.js:72:36)
    at resolveOne (B:\Projects\Parse Server\parse-server\node_modules\parse\lib\node\ParsePromise.js:471:29)
    at ParsePromise.object.then.errors.(anonymous function) (B:\Projects\Parse Server\parse-server\node_modules\parse\lib\node\ParsePromise.js:480:13)
    at ParsePromise.wrappedResolvedCallback (B:\Projects\Parse Server\parse-server\node_modules\parse\lib\node\ParsePromise.js:139:41)
    at ParsePromise.resolve (B:\Projects\Parse Server\parse-server\node_modules\parse\lib\node\ParsePromise.js:72:36)
    at ReadFileContext.callback (B:\Projects\Parse Server\parse-server\src\Adapters\Logger\FileLoggerAdapter.js:9:16189)
    at FSReqWrap.readFileAfterOpen [as oncomplete] (fs.js:303:13)
```
Rest of the tests could not be run as the test runner would break here. This change adds a check to fail when the FileLoggerAdapter returns an empty array from here: https://github.com/ParsePlatform/parse-server/blob/master/src/Adapters/Logger/FileLoggerAdapter.js#L191

Regarding the cause of the error itself, it is due to different filename separators in *nix and Windows. The FileLoggerAdapter would not save logs (have not tested this). This is a separate issue and should also be fixed.
2016-03-10 11:17:52 +05:30
Florent Vilmart
ddd1ae3338 Validates key, values and operation in CLP 2016-03-09 20:19:12 -05:00
Florent Vilmart
e75d233b7e Adds validation of addFields 2016-03-09 19:33:48 -05:00
Florent Vilmart
5780c1e425 Merges CLP endpoints with POST, PUT and GET 2016-03-09 19:33:47 -05:00
Florent Vilmart
d4fd73100c Adds CLP API to Schema router 2016-03-09 19:33:47 -05:00
Nikita Lutsenko
e93873f7b1 Do not require where clause in condition on queries. 2016-03-08 17:08:27 -08:00
Nikita Lutsenko
0f07c5204e Add test validating that we have ACL propagate to before/after save hooks. 2016-03-08 16:15:49 -08:00
Florent Vilmart
bd7d951ad6 default encoding is now querystring instead of JSON 2016-03-08 08:12:30 -05:00
Florent Vilmart
6acb5cee80 ES6-ify 2016-03-08 08:04:34 -05:00
Florent Vilmart
f40efe3923 Sets encoding to null to preserve raw buffers 2016-03-08 07:55:44 -05:00
Florent Vilmart
8300dd8a47 Encodes the body by default to application/json if is object 2016-03-08 07:54:23 -05:00
Carmen
440099267d #911 support params option in Parse.Cloud.httpRequest 2016-03-08 20:23:55 +08:00
Nikita Lutsenko
0abd5a5931 Re-enable GeoPoint test. 2016-03-07 22:47:18 -08:00
Nikita Lutsenko
98769a2226 Merge pull request #902 from ParsePlatform/flovilmart.FixPushNotifications
Increment badge the right way
2016-03-07 20:44:24 -08:00
Florent Vilmart
80869749aa Merge pull request #708 from mcdonamp/mcdonald-gcs-adapter
Yet Another FileAdapter: Google Cloud Storage
2016-03-07 23:26:21 -05:00
Florent Vilmart
bf96f0d28a Fixes problems related to increment badge
- name conventions are aweful in PushController
- properly looks at the badge into body.data instead of body
- We may want to refactor that as it's confusing to use a full body
2016-03-07 22:07:15 -05:00
Nikita Lutsenko
654a540b6a Fix race condition in GlobalConfig test. 2016-03-07 17:22:27 -08:00
Nikita Lutsenko
de0f71cc9e Remove useless masterKey validation in PushController.sendPush. 2016-03-07 17:22:27 -08:00
Nikita Lutsenko
47061d8e98 Migrate PushRouter to shared master-key middleware. 2016-03-07 17:22:27 -08:00
Nikita Lutsenko
7909f0efe0 Merge pull request #900 from drew-gross/schemas-500
Handle legacy _client_permissions key in _SCHEMA. Fixes #888.
2016-03-07 17:08:58 -08:00
Nikita Lutsenko
fa6954169e Migrate ParseGlobalConfig.spec to new database storage API. 2016-03-07 14:11:43 -08:00
Drew Gross
963811d022 Handle legacy _client_permissions key in _SCHEMA. Fixes #888. 2016-03-07 13:44:45 -08:00
Florent Vilmart
75ae95815d Merge pull request #887 from ParsePlatform/flovilmart.fixDoubleRelationPointerEqualContraint
Fixes bug when querying equalTo on objectId and relation
2016-03-07 10:37:49 -05:00
Florent Vilmart
5cdcadea36 Fixes bug when querying equalTo on objectId and relation
- Adds $eq operator in transform
- Makes $eq operator on objectId when adding $in operator
2016-03-07 08:26:35 -05:00