Skip to content

Commit

Permalink
EVEN MORE FIXES
Browse files Browse the repository at this point in the history
  • Loading branch information
WardPearce committed Jun 9, 2021
1 parent a720406 commit e8e8fad
Showing 1 changed file with 8 additions and 36 deletions.
44 changes: 8 additions & 36 deletions src/test/dathost.test.ts
Expand Up @@ -58,10 +58,9 @@ describe('Dathost Tests', () => {
})

afterEach(async () => {
try {
expect(async () => {
await server[1].delete()
// eslint-disable-next-line no-empty
} catch { }
}).not.toThrow()
})

it('Server return', async () => {
Expand Down Expand Up @@ -158,12 +157,6 @@ describe('Dathost Tests', () => {
}
})

it('Delete server', async () => {
expect(async () => {
await server[1].delete()
}).not.toThrow()
})

it('Create match', async () => {
const matchServer = await dathost.createServer(new ServerSettings({
name: 'TS CS:GO Match',
Expand Down Expand Up @@ -217,10 +210,9 @@ describe('Dathost Tests', () => {
})

afterEach(async () => {
try {
expect(async () => {
await server[1].delete()
// eslint-disable-next-line no-empty
} catch { }
}).not.toThrow()
})

it('Get server details', async () => {
Expand Down Expand Up @@ -288,22 +280,15 @@ describe('Dathost Tests', () => {
expect(file[1]).toBeInstanceOf(File)
}
})

it('Delete server', async () => {
expect(async () => {
await server[1].delete()
}).not.toThrow()
})
})

describe('Valheim server', () => {
let server: [IServer, Server]

afterEach(async () => {
try {
expect(async () => {
await server[1].delete()
// eslint-disable-next-line no-empty
} catch { }
}).not.toThrow()
})

beforeEach(async () => {
Expand Down Expand Up @@ -377,12 +362,6 @@ describe('Dathost Tests', () => {
await server[1].consoleSend('say https://github.com/UnofficialDathost/TypeScript')
}).not.toThrow()
})

it('Delete server', async () => {
expect(async () => {
await server[1].delete()
}).not.toThrow()
})
})

describe('Teamspeak server', () => {
Expand All @@ -396,10 +375,9 @@ describe('Dathost Tests', () => {
})

afterEach(async () => {
try {
expect(async () => {
await server[1].delete()
// eslint-disable-next-line no-empty
} catch { }
}).not.toThrow()
})

it('Get server details', async () => {
Expand Down Expand Up @@ -448,11 +426,5 @@ describe('Dathost Tests', () => {
await server[1].syncFiles()
}).not.toThrow()
})

it('Delete server', async () => {
expect(async () => {
await server[1].delete()
}).not.toThrow()
})
})
})

0 comments on commit e8e8fad

Please sign in to comment.