Use testcontainer reuse
This commit is contained in:
parent
bfaa196a33
commit
e8201ea490
|
@ -21,6 +21,7 @@ describe("oauth2 utils", () => {
|
||||||
|
|
||||||
container = await new GenericContainer(keyClockImage)
|
container = await new GenericContainer(keyClockImage)
|
||||||
.withName("keycloak_testcontainer")
|
.withName("keycloak_testcontainer")
|
||||||
|
.withReuse()
|
||||||
.withExposedPorts(8080)
|
.withExposedPorts(8080)
|
||||||
.withBindMounts([
|
.withBindMounts([
|
||||||
{ source: volumePath, target: "/opt/keycloak/data/import/" },
|
{ source: volumePath, target: "/opt/keycloak/data/import/" },
|
||||||
|
@ -35,10 +36,6 @@ describe("oauth2 utils", () => {
|
||||||
)}`
|
)}`
|
||||||
})
|
})
|
||||||
|
|
||||||
afterAll(async () => {
|
|
||||||
await container.stop()
|
|
||||||
})
|
|
||||||
|
|
||||||
describe("generateToken", () => {
|
describe("generateToken", () => {
|
||||||
it("successfully generates tokens", async () => {
|
it("successfully generates tokens", async () => {
|
||||||
const response = await config.doInContext(config.appId, async () => {
|
const response = await config.doInContext(config.appId, async () => {
|
||||||
|
|
Loading…
Reference in New Issue