Commit graph

1427 commits

Author SHA1 Message Date
Shane Kilkelly
c423672b55 Unit test for finishLogin 2018-07-18 12:08:34 +01:00
Shane Kilkelly
943bfe98aa Unit test for _loginAsyncHandlers 2018-07-18 11:13:42 +01:00
Shane Kilkelly
dae9506f84 Un-break unit tests 2018-07-18 09:57:05 +01:00
Alasdair Smith
62f69a4bcd Fix case sensitivity 2018-07-18 09:26:03 +01:00
Alasdair Smith
823e12e4a8 Fix tests to add new Features dependency 2018-07-18 09:26:03 +01:00
James Allen
c2777918fa Add some missing unit test mocks 2018-07-17 11:26:07 +01:00
James Allen
2c25cbaf25 Update error handling on backend 2018-07-17 11:12:09 +01:00
Alberto Fernández-Capel
e7738b851d Merge pull request #764 from sharelatex/afc-import-managers
Import managers
2018-07-17 10:10:51 +01:00
James Allen
ca97698724 Handle v1 response when email is already in use 2018-07-16 17:27:01 +01:00
Hayden Faulds
04bb83f3de add v2 history labels endpoints 2018-07-16 16:06:17 +01:00
Alberto Fernández Capel
66b492ba5f Use id to find subscription
It's the new method signature.
2018-07-16 14:42:41 +01:00
Alberto Fernández Capel
ae440f2ee6 Better variable name in test
It should be a subscription id, instead of an admin id. The test passes
anyway because the db calls are mocked, but the wrong variable name
can cause confusion.
2018-07-16 14:40:53 +01:00
James Allen
d0f77abc70 Update email in v1 when setting default in v2 2018-07-16 13:26:52 +01:00
James Allen
b150a7b4ae Merge pull request #735 from sharelatex/pr-affiliations-ui-adjustments
Affiliations UI, second round
2018-07-16 10:08:47 +01:00
Alberto Fernández Capel
0bf807fa9f Remove SubscriptionLocator.getManagedSubscription
It was used as a kind of access control check, but it's clearer
if the check is in the only controller that actually needs it.
2018-07-13 11:47:26 +01:00
James Allen
476f4e55c3 Just generate a new token on resending confirmation email 2018-07-13 10:42:31 +01:00
Alberto Fernández Capel
46a1cdc510 Use the admin_ids array to query for subscriptions 2018-07-13 09:38:58 +01:00
James Allen
33b28db061 Add backend endpoint for resending confirmation email 2018-07-12 16:39:04 +01:00
Alberto Fernández Capel
abcfa0b0d2 Store manager ids in an array 2018-07-12 16:35:27 +01:00
Tim Alby
35cb3924e2 refresh features after confirming email 2018-07-11 14:57:35 +02:00
Alberto Fernández Capel
3586fe8406 Update var name 2018-07-11 11:50:14 +01:00
Alberto Fernández Capel
4e8185d369 Use the id in methods that modify a subscription
This will make it easier to allow a user to manage multiple
groups.
2018-07-11 09:56:36 +01:00
Tim Alby
791dc0df5b check institution features on features update 2018-07-10 17:53:37 +02:00
James Allen
91079f3af2 Fix unit tests 2018-07-10 11:32:19 +01:00
James Allen
cb449f4b75 Delete a subscription on expiry, rather than set personal plan code 2018-07-10 10:31:25 +01:00
James Allen
7a1bb30952 Merge pull request #699 from sharelatex/ja-fix-bonus-feature-allocation
Don't consider current features when assigning bonus
2018-07-06 11:06:34 +01:00
Tim Alby
b78212290a handle dynamic Proxy URLs 2018-07-06 12:03:47 +02:00
Tim Alby
cfd5c65be4 add affiliation before confirming email 2018-07-05 16:02:55 +02:00
Tim Alby
9d4df4271a try adding affiliation on user creation 2018-07-05 16:01:15 +02:00
Tim Alby
3e1d61438f add endpoint to endorse affiliation 2018-07-05 15:59:36 +02:00
Timothée Alby
958012533d Merge pull request #724 from sharelatex/ta-parse-email
parse email in UserUpdater
2018-07-05 15:57:20 +02:00
Hugh O'Brien
a230b5efab Merge pull request #720 from sharelatex/mm-export-v1projectid
Include project's and user's v1 ID in export requests
2018-07-05 12:12:35 +01:00
Shane Kilkelly
0777e44abf Merge branch 'sk-linked-files-mendeley' 2018-07-04 12:16:39 +01:00
Shane Kilkelly
b32c9be8ca Linked files from Mendeley. 2018-07-04 10:05:03 +01:00
Tim Alby
3a541307b4 parse email in UserUpdater 2018-07-03 20:59:38 +02:00
Alberto Fernández-Capel
f1ef053caf Merge pull request #705 from sharelatex/afc-import-team-from-v1
Changes to allow importing a team from v1
2018-07-03 13:39:19 +01:00
Alberto Fernández-Capel
d904622b05 Merge pull request #695 from sharelatex/sk-fix-validation-on-refresh-output-file
Fix validation of project-output-file, no build_id when imported from v1
2018-07-03 13:38:59 +01:00
Michael Mazour
235534d269 Also include user's v1 ID in export requests 2018-07-03 10:15:51 +01:00
Douglas Lovell
260f927980 Merge pull request #719 from sharelatex/dcl-test-fix
Small repair to SubscriptionController Test
2018-07-02 13:16:10 -03:00
Paulo Reis
80b7641652 Update UserEmails acceptance tests to use the new POST-based email deletion endpoint. 2018-07-02 12:31:36 +01:00
Alasdair Smith
ec1dbc47bf Merge pull request #703 from sharelatex/as-cm-pos-assertion
Add assertion method for CodeMirror Pos objects
2018-07-02 11:35:26 +01:00
Michael Mazour
8436b67260 Include project's v1 ID in export requests
If a project was imported from v1, include its v1 ID when making an export request back to v1.

Use case: v1 project exported via ScholarOne and then migrated to v2 needs to be linked up to its earlier v1 export records.
2018-07-02 11:12:42 +01:00
Douglas Lovell
1df5b0b942 Fixup mixed indentation 2018-06-29 19:36:59 -03:00
Douglas Lovell
20835a79e2 Repair not logged in subscription controller test 2018-06-29 19:36:40 -03:00
Alberto Fernández Capel
18ded60619 Fix unit tests 2018-06-28 15:28:44 +01:00
Alberto Fernández Capel
193579070c Ensure features are updated for users but not for stubs 2018-06-28 13:25:04 +01:00
Tim Alby
fe0fdd11bf call v1 affiliation deletion endpoint with POST instead of DELETE 2018-06-28 13:48:28 +02:00
Tim Alby
1d80878bf8 delete affiliations on user deletion 2018-06-28 13:47:19 +02:00
Tim Alby
837f614df4 refactor affiliation requests 2018-06-28 13:47:16 +02:00
Alberto Fernández Capel
4366a0ea2c Remove trailing whitespace 2018-06-28 11:08:20 +01:00
Tim Alby
8c70ba88b7 Add missing greater-than character in tests 2018-06-28 10:15:55 +02:00
Alberto Fernández Capel
c19fc6d245 Fetch the whole user doc
Other attributes are needed to calculate features.
2018-06-27 12:52:47 +01:00
Alberto Fernández Capel
8b8742d60f Fix ReferalFeatures tests 2018-06-27 12:28:22 +01:00
Alasdair Smith
3a90a2d004 Add custom assertion method to chai for comparing CM Pos objects 2018-06-27 11:28:29 +01:00
James Allen
156c417df0 Don't consider current features when assignin bonus 2018-06-26 11:26:07 +01:00
Henry Oswald
c1a8d8b31a Merge branch 'master' into ho-clsi-double-backend 2018-06-25 13:43:40 +01:00
Tim Alby
c6de896bb5 decorate emails list with affiliation data 2018-06-25 13:47:04 +02:00
Tim Alby
c81f9c24ed mock affiliations API in acceptance tests 2018-06-25 13:45:46 +02:00
Tim Alby
e41391fb4a ignore affiliations if v1 is not configured 2018-06-25 13:45:46 +02:00
Tim Alby
d3b2a2650f add/remove affiliations when adding/removing emails 2018-06-25 13:45:46 +02:00
Shane Kilkelly
04be842b30 Fix validation of project-output-file, no build_id for imported v1 projects 2018-06-25 12:27:56 +01:00
Tim Alby
b65ba388ba replace OldAssetProxy 2018-06-25 12:36:51 +02:00
Shane Kilkelly
f6424ada40 Merge pull request #655 from sharelatex/sk-linked-files-output-redux
Linked files from project output
2018-06-25 10:28:29 +01:00
James Allen
0a2fe7e941 Merge pull request #687 from sharelatex/ja-fix-subscription-upsell
Fix check for hasSubscription
2018-06-22 15:59:51 +01:00
James Allen
0edd2b5fe7 Fix check for hasSubscription 2018-06-22 14:10:20 +01:00
Shane Kilkelly
d76c6c2c22 Merge pull request #682 from sharelatex/sk-copy-linked-file-data-on-clone
Copy linkedFileData when cloning a project
2018-06-22 13:22:45 +01:00
Shane Kilkelly
a8222f2e31 Fix tests after sync with master 2018-06-22 13:20:13 +01:00
Shane Kilkelly
ebe828aa62 Refactor, and remove the source_project_display_name prop from linkedFileData 2018-06-22 13:09:18 +01:00
Shane Kilkelly
6058f3ef9b Refactor the LinkedFiles/Agent system, and track build_id for output files 2018-06-22 13:09:18 +01:00
Shane Kilkelly
2ade78783b Add acceptance test for refreshing output file from v1 project 2018-06-22 13:09:18 +01:00
Shane Kilkelly
28257462ae Acceptance tests for project-output-file 2018-06-22 13:09:18 +01:00
Shane Kilkelly
fadbd72837 Add unit test for copying project with linked files 2018-06-22 10:52:49 +01:00
Alberto Fernández-Capel
d36dbfda07 Merge pull request #665 from sharelatex/afc-import-team-invites
Add method to import invites
2018-06-22 09:55:19 +01:00
Timothée Alby
caee25d85d Revert "Replace OldAssetsProxy" 2018-06-21 15:52:20 +02:00
Timothée Alby
c30cdf955b Merge pull request #666 from sharelatex/ta-smart-proxy
Replace OldAssetsProxy
2018-06-21 14:35:16 +02:00
James Allen
de45c08585 Restrict token look ups by id to not conflict with other tests 2018-06-21 11:00:25 +01:00
James Allen
46fbf0c641 Merge pull request #672 from sharelatex/ja-refactor-email-templating
Refactor email templating
2018-06-21 10:28:26 +01:00
James Allen
4608a59e3d Store OneTimeTokens in mongo rather than redis 2018-06-21 10:22:08 +01:00
James Allen
0dcbc5facb Send out confirmation emails on register and record confirmedAt date 2018-06-21 10:21:15 +01:00
Henry Oswald
5a7b8f4887 fix broken test for compile controller 2018-06-20 13:44:07 +01:00
Alasdair Smith
6c1994e25b Stub errors in tests to cache 2018-06-20 11:19:23 +01:00
Henry Oswald
e60157094b improve logging for 2 compile backends 2018-06-20 11:07:34 +01:00
Tim Alby
bbed5fca9a simplify proxy 2018-06-20 10:58:19 +02:00
Henry Oswald
b5581c4d40 Merge branch 'master' into ho-clsi-double-backend 2018-06-19 14:55:18 +01:00
Henry Oswald
ab0f258c03 don't make request to google cloud clsi if there is no url 2018-06-19 14:22:34 +01:00
Michael Mazour
0246631443 Add public API endpoints to reach CLSIs
- `/api/clsi/compile/:submission_id`
- `/api/clsi/compile/:submission_id/build/:build_id/output/:file`

Also per review:
- DRY up ClsiManager.sendRequestOnce and ClsiManager.sendExternalRequest
- Include submission_id in a log message
- Don't include timeout in limits when getting file
2018-06-19 12:04:02 +01:00
Tim Alby
3d272ca297 replace OldAssetProxy 2018-06-18 18:37:58 +02:00
Alberto Fernández Capel
81c102b501 Add method to import invites 2018-06-18 14:48:27 +01:00
Henry Oswald
5f8985811d mvp to send requests to 2 backends 2018-06-14 17:41:30 +01:00
Timothée Alby
55112dc7dc Merge pull request #648 from sharelatex/hb-export-status
Export status endpoint
2018-06-14 13:59:11 +02:00
Timothée Alby
984d81f5b8 Merge pull request #649 from sharelatex/ta-emails-endpoints
Add Emails Endpoints
2018-06-14 13:59:00 +02:00
hugh-obrien
0321780eba adding tests for exports status checker 2018-06-14 09:44:05 +01:00
James Allen
c60b74a2b1 Merge pull request #652 from sharelatex/ja-fix-front-end-test
Fix frontend HistoryV2ManagerTests
2018-06-14 09:11:32 +01:00
James Allen
82c6d9b293 Merge pull request #629 from sharelatex/ja-display-subscriptions
Link subscriptions to v1
2018-06-13 13:55:57 +01:00
Shane Kilkelly
3baf0836bc Support project-linked-files originating from imported v1 projects 2018-06-13 10:02:54 +01:00
James Allen
6e2ec2f982 Update remaining unit tests 2018-06-12 13:52:47 +01:00
James Allen
28f51cd4b4 Update SubscriptionController unit tests 2018-06-12 13:52:47 +01:00
James Allen
606419476f Update LimitationsManager unit tests 2018-06-12 13:52:47 +01:00
James Allen
f7532e5854 Merge pull request #619 from sharelatex/afc-email-tokens
Use emails with tokens for team invites
2018-06-12 08:30:23 +01:00
James Allen
d4efdb3ede Fix frontend HistoryV2ManagerTests 2018-06-11 15:47:23 +01:00