测试:修改一些令测试失败的问题
This commit is contained in:
@@ -58,7 +58,7 @@ function testGroupMsg(pinusClient: PinusWSClient, roleInfo: any, pinusClientT: P
|
|||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
expect(msgReceiveCnt).to.be.equal(2);
|
expect(msgReceiveCnt).to.be.equal(2);
|
||||||
done();
|
done();
|
||||||
}, 1000);
|
}, 2000);
|
||||||
});
|
});
|
||||||
}, 100);
|
}, 100);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -84,7 +84,8 @@ describe('寻宝创建队伍', function() {
|
|||||||
pinusClient.on('onTeamJoin', (msg) => {
|
pinusClient.on('onTeamJoin', (msg) => {
|
||||||
checkSuccessResponse(msg);
|
checkSuccessResponse(msg);
|
||||||
});
|
});
|
||||||
pinusClient.request('role.heroHandler.addItem', { id: createTeamParms.blueprtId, count: 1 }, res => {
|
pinusClient.request('role.heroHandler.addItem', { id: createTeamParms.blueprtId, count: 10 }, res => {
|
||||||
|
checkSuccessResponse(res);
|
||||||
pinusClient.request('battle.comBattleHandler.createTeam', createTeamParms, (res) => {
|
pinusClient.request('battle.comBattleHandler.createTeam', createTeamParms, (res) => {
|
||||||
checkSuccessResponse(res);
|
checkSuccessResponse(res);
|
||||||
expect(res.data.teamCode).to.be.a('string');
|
expect(res.data.teamCode).to.be.a('string');
|
||||||
|
|||||||
@@ -3,12 +3,9 @@ import 'mocha';
|
|||||||
import { PinusWSClient } from 'pinus-robot-plugin';
|
import { PinusWSClient } from 'pinus-robot-plugin';
|
||||||
import { expect } from 'chai';
|
import { expect } from 'chai';
|
||||||
import { checkSuccessResponse, checkDisplayItems } from './CheckPatten';
|
import { checkSuccessResponse, checkDisplayItems } from './CheckPatten';
|
||||||
import { DEBUG_MAGIC_WORD, AUCTION_SOURCE, CURRENCY_BY_TYPE, CURRENCY_TYPE, AUCTION_STAGE, DIVIDEND_STATUS } from '../app/consts';
|
import { DEBUG_MAGIC_WORD } from '../app/consts';
|
||||||
import { LOT_STATUS, TASK_FUN_TYPE } from '../../shared/consts';
|
import { TASK_FUN_TYPE } from '../../shared/consts';
|
||||||
import { take } from 'underscore';
|
|
||||||
|
|
||||||
const GOOD_ID_TIEJIAN = 1;
|
|
||||||
const GOOD_ID_GANGJIAN = 2;
|
|
||||||
|
|
||||||
describe('任务测试', function () {
|
describe('任务测试', function () {
|
||||||
let pinusClient: PinusWSClient;
|
let pinusClient: PinusWSClient;
|
||||||
@@ -16,9 +13,8 @@ describe('任务测试', function () {
|
|||||||
|
|
||||||
beforeEach(function (done) {
|
beforeEach(function (done) {
|
||||||
const c = new Client();
|
const c = new Client();
|
||||||
const cT = new Client('13121622738');
|
|
||||||
const timer = setInterval(() => {
|
const timer = setInterval(() => {
|
||||||
if (c.client && cT.client) {
|
if (c.client) {
|
||||||
pinusClient = c.client;
|
pinusClient = c.client;
|
||||||
roleInfo = c.roleInfo;
|
roleInfo = c.roleInfo;
|
||||||
clearInterval(timer);
|
clearInterval(timer);
|
||||||
|
|||||||
Reference in New Issue
Block a user