mirror of
https://github.com/hack-chat/main.git
synced 2024-03-22 13:20:33 +08:00
Removed obsolete test cases
This commit is contained in:
parent
2bbb507f01
commit
b80b5ca9d1
|
@ -91,20 +91,6 @@ describe('Checking changenick module', () => {
|
|||
|
||||
expect(resp).to.be.true;
|
||||
});
|
||||
|
||||
it('should prevent admin impersonation', async () => {
|
||||
const resp = await importedModule.run({
|
||||
core: mocks.core,
|
||||
server: mocks.server,
|
||||
socket: mocks.plebSocket,
|
||||
payload: {
|
||||
cmd: 'changenick',
|
||||
nick: 'admin',
|
||||
},
|
||||
});
|
||||
|
||||
expect(resp).to.be.true;
|
||||
});
|
||||
|
||||
it('should not update if there is no change', async () => {
|
||||
const resp = await importedModule.run({
|
||||
|
|
|
@ -139,25 +139,6 @@ describe('Checking join module', () => {
|
|||
expect(resp).to.be.true;
|
||||
});
|
||||
|
||||
it('should prevent admin impersonation', async () => {
|
||||
const newSocket = Object.assign({}, mocks.authedSocket);
|
||||
newSocket.channel = undefined;
|
||||
newSocket.hcProtocol = undefined;
|
||||
|
||||
const resp = await importedModule.run({
|
||||
core: mocks.core,
|
||||
server: mocks.server,
|
||||
socket: newSocket,
|
||||
payload: {
|
||||
cmd: 'join',
|
||||
nick: 'admin#test',
|
||||
channel: 'cake',
|
||||
},
|
||||
});
|
||||
|
||||
expect(resp).to.be.true;
|
||||
});
|
||||
|
||||
it('should prevent two of the same name in the same channel', async () => {
|
||||
const newSocket = Object.assign({}, mocks.authedSocket);
|
||||
newSocket.channel = undefined;
|
||||
|
|
Loading…
Reference in New Issue
Block a user