Commit Graph

46 Commits

Author SHA1 Message Date
Mitch-Budibase c949493016 QA Core - Manage License Test Change
The pricing has changed.

Previously we used `PREMIUM` and `BUSINESS`.
We now use `PREMIUM_PLUS` and `ENTERPRISE_BASIC`
The test changes reflect this
2024-01-09 14:55:43 +00:00
Adria Navarro db2c20e3ae eslint import/newline-after-import 2023-11-20 21:52:29 +01:00
Adria Navarro 92f411bf77 Prettier 2023-11-20 21:48:49 +01:00
Adria Navarro 4d27ff1dc0 eslint import/no-duplicates 2023-11-20 21:48:49 +01:00
Mitch-Budibase 85325814d0 Moving stripe import to top of test file 2023-11-01 15:18:20 +00:00
Mitch-Budibase 84079450f9 lint 2023-10-31 18:20:27 +00:00
Mitch-Budibase e05821d6d7 License Management Test
This test retrieves plans, creates checkout session, and updates license

Essential changes have been made to linkStripeCustomer & updatePlan functions to support the test

Modified "test:self:ci" to include 'licensing' instead of 'license'
Modified environment.ts to include STRIPE_SECRET_KEY
2023-10-31 18:16:58 +00:00
Mitch-Budibase 570eaa8e53 Update package.json + remove license.manage.spec.ts
Update package.json
- Updating "test:self:ci"
- Now includes license. Needed to prevent license tests from running where an account portal is not setup

Removing license.manage.spec.ts
- This will be included in another PR
- Work required to finish this test
- Removing so the license activation test can be merged
2023-10-24 17:22:49 +01:00
Mitch-Budibase f3234f6bd6 Update license activate test
I have removed the end of the test which was to 'Verify user downgraded to free license'
- This is not needed

I have also updated getLicenseKey - specifically how it handles the expected 200 response
2023-10-06 16:22:56 +01:00
Mitch-Budibase 5e16d04519 lint 2023-10-05 17:43:25 +01:00
Mitch-Budibase 678033cc8b License Key - Activate & Manage Tests
There are two test files, license.activate.spec.ts and license.manage.spec.ts

These test files each contain a test:
- Creates, activates, and deletes an online license for a self hosted account - license.activate.spec.ts
- Retrieves plans, creates checkout session, and updates license - license.manage.spec.ts

Updated and created API files
- StripeAPI
- LicenseAPI
- internal-api LicenseAPI
- index & AccountInternalAPI also updated to reflect API file changes
2023-10-05 17:39:40 +01:00
Mitch-Budibase 18a159e912 Add assertion for self response
We want to ensure that the self response contains the email of the created account
2023-09-01 15:43:07 +01:00
Mitch-Budibase 3c3dd9c95a Updating test - performs signup and deletion flow
Including two more steps within this test.

- Verify the self response is unauthorized
- Verify the self response matches the account

This will cover the '/api/auth/self' endpoint
2023-08-01 16:46:11 +01:00
Mitch-Budibase 2e827bcc8e Moving 'self' function from AuthAPI to AccountAPI
This function will be used within Account testing
2023-07-31 18:01:40 +01:00
Mitch-Budibase fe9dded2ab Updating Describe text
It previously said 'Accounts' but 'Password Management' is more accurate for the test
2023-07-31 17:45:45 +01:00
jvcalderon 17980d4bcc Merge account-portal-auth-api-testing 2023-07-31 16:09:45 +02:00
Rory Powell f656e97d2d Lint 2023-07-25 11:28:14 +01:00
Rory Powell ccf98580d6 Merge branch 'develop' into tests/offline-license 2023-07-25 11:24:09 +01:00
Rory Powell 6aac59c248 Add ignore to offline licensing test 2023-07-25 11:12:36 +01:00
Mitch-Budibase d4b7ac9c98 Generate guid to replace encodeURIComponent
Removing encodeURIComponent(accountId) in favour of generating a guid
2023-07-21 17:45:17 +01:00
Mitch-Budibase aeda2a143e Update accounts.cloud.internal.spec.ts
We use a randomly generated string for the accountId.

It would seem that when an accountId includes a percentage sign (%) at the end, that issues arise (400 returned instead of 404 in this case).

I have included a encodeURIComponent for the accountId after it has been generated
2023-07-21 13:30:56 +01:00
Rory Powell 0d08a38ec7 Merge branch 'feature/offline-license' into tests/offline-license 2023-07-20 12:28:51 +01:00
Rory Powell f641341dac Merge branch 'account-api-tests' of github.com:Budibase/budibase into account-api-tests 2023-07-20 09:23:04 +01:00
Rory Powell 8f2d8a7b64 Update test commands to ignore cloud specific tests in CI 2023-07-20 09:21:38 +01:00
Mitch-Budibase ec5203f775 PR changes 2023-07-19 17:31:33 +01:00
Mitch-Budibase ecf75a9685 lint 2023-07-19 15:42:12 +01:00
Mitch-Budibase b01c800d08 Updating comments 2023-07-19 15:18:02 +01:00
Rory Powell 4dc558d3e9 Restructure account tests to test signup and deletion as a single flow 2023-07-18 21:15:13 +01:00
Rory Powell 944b6e0baa Update account api clients to consistently handle status code handling and return types 2023-07-18 21:14:07 +01:00
Mitch-Budibase ea91605e2f Updates to account endpoint API testing 2023-07-18 13:48:23 +01:00
Rory Powell ea52013503 Offline licensing integration tests 2023-07-15 00:12:18 +01:00
Rory Powell 278f6f8df3 Update account search tests / add email to state 2023-07-14 15:23:22 +01:00
Rory Powell f45a439b26 Add state helpers for isolating account deletion test 2023-07-14 15:03:51 +01:00
Mitch-Budibase fa94b8b9fc Changes for Account API Testing 2023-07-14 14:24:01 +01:00
Rory Powell 6f7ef18084 Add account password login integration with global setup 2023-07-13 12:48:44 +01:00
Mitch-Budibase d8d4686e01 Account Portal API Testing 2023-07-13 12:36:50 +01:00
mike12345567 289a75fc9a Few minor updates to the integration suite to make it easier to decipher what is happening under the hood, as well as making it easier to log from these (where there is no pino logging available, importing backend-core breaks things). Also added a new script which can be used to get local environment setup as needed to run qa-core tests. Finally, xdescribe for the failing test until can work out what is wrong with MongoDB installation in QA environment. 2023-06-19 18:28:38 +01:00
mike12345567 d0d3e33606 Fixing linting. 2023-06-12 16:29:41 +01:00
Rory Powell 7bd7cdcdcf Fix qa-core global teardown 2023-06-12 15:08:22 +01:00
Rory Powell 25fc792d24 Fix qa-core teardown 2023-06-09 21:04:24 +01:00
Pedro Silva 91a8888890 Add teardown logic for multitenancy 2023-05-30 15:08:37 +01:00
Pedro Silva 9b8e2718ed Linting 2023-05-12 12:27:34 +01:00
Pedro Silva e792b717c5 Update qa-core/src/account-api/api/apis/LicenseAPI.ts
Co-authored-by: Rory Powell <rory.codes@gmail.com>
2023-05-12 12:16:48 +01:00
Pedro Silva 85c835e5f0 Add status check to license api 2023-05-12 11:14:00 +01:00
Rory Powell aee52af7f0 Add feature and quota overrides to qa core for cloud tests (#10417)
* Fix qa core suite

* Update package.json

* Lint
2023-04-25 20:36:27 +01:00
Rory Powell 77ffb8d86d Run integration suite in CI again / auto detect tenancy / refactors (#10209)
* qa-core-ci-fixes

* global setup and teardown wip

* Updates to logs and setup

* Remove date and console mocking

* Update CI to spin up minimal dev env

* Update readme

* Fix scopeBackend.sh

* Ensure docker services are initialised before starting worker

* Lint

* Fix admin user being created on startup (#10219)

* use regular bootstrap and build

* Lint

* Temp: re-use global setup to get around app limit in QA
2023-04-05 15:33:56 +01:00