rename data -> structures

This commit is contained in:
Rory Powell 2022-04-06 22:00:10 +01:00
parent b650863a2b
commit e3cf9b0661
4 changed files with 6 additions and 6 deletions

View File

@ -1,7 +1,7 @@
const mocks = require("./mocks")
const data = require("./data")
const structures = require("./structures")
module.exports = {
mocks,
data,
structures,
}

View File

@ -1,8 +1,8 @@
require("../mocks")
const koa = require("./koa")
const data = {
const structures = {
koa,
}
module.exports = data
module.exports = structures

View File

@ -1,11 +1,11 @@
const { data } = require("./utilities")
const { structures } = require("./utilities")
const utils = require("../utils")
const events = require("../events")
describe("utils", () => {
describe("platformLogout", () => {
it("should call platform logout", async () => {
const ctx = data.koa.newContext()
const ctx = structures.koa.newContext()
await utils.platformLogout({ ctx, userId: "test" })
expect(events.auth.logout.mock.calls.length).toBe(1)
})