1
0
Fork 0
mirror of synced 2024-09-20 11:27:56 +12:00
budibase/packages/worker/src/tests/api/license.ts
Peter Clement 9d841bc947 Server and Worker tests (#8928)
* automation unit tests

* row processor tests

* update executeQuery test

* update groups assertion

* some more worker tests

* plugin tests and tidying up

* linting

* temporarily disable group tests

* more tests

* fix import

* fix backup tests

* add pro mocks to worker

* check for app existence in import test

* test new tsconfig

* testing changes

* Pro test utils (#9020)

* Pro test utils changes

* Add test fixes

* Remove ts-ignore

Co-authored-by: mike12345567 <me@michaeldrury.co.uk>
Co-authored-by: Rory Powell <rory.codes@gmail.com>
2022-12-12 22:02:32 +00:00

17 lines
452 B
TypeScript

import TestConfiguration from "../TestConfiguration"
import { TestAPI } from "./base"
export class LicenseAPI extends TestAPI {
constructor(config: TestConfiguration) {
super(config)
}
activate = async (licenseKey: string) => {
return this.request
.post("/api/global/license/activate")
.send({ licenseKey: licenseKey })
.set(this.config.defaultHeaders())
.expect("Content-Type", /json/)
.expect(200)
}
}