diff --git a/client/tests/test_rpc_send.js b/client/tests/test_rpc_send.js index 50a7253..8b61940 100644 --- a/client/tests/test_rpc_send.js +++ b/client/tests/test_rpc_send.js @@ -43,8 +43,15 @@ t.eq('提示', call(() => EQW_Rpc.tishi(1)).data, { seat: 2, tip: 1 }); t.eq('准备', call(() => EQW_Rpc.zhunbei()).data, { seat: 2 }); // ---- 【核心】只带意图:所有发包的字段集合不含任何结论字段 ---- +// FORBIDDEN 列表:协议中服务端→客户端方向的字段名。原则上都不该出现在客户端→服务端的包里。 +// 作为回归网:新增发包方法时若引入了服务端字段名会被它拦下。 const FORBIDDEN = ['score', 'isWin', 'phase', 'nextSeat', 'nextseat', 'handCards', - 'grade', 'multiple', 'result', 'banker', 'curmultiple', 'upgrade']; + 'grade', 'multiple', 'result', 'banker', 'curmultiple', 'upgrade', + 'cardsinhand', 'mustcard', 'seatlist', 'baozhu', 'liangpai', 'bottomcards', 'burycards', + 'ancard3s', 'countdown', 'currcall', 'chongguan', 'wang', 'naward', + 'grade_aw', 'grade_cg', 'grade_bw', 'grade_jf', 'account', 'readystate', + 'shuai', 'shuaicuo', 'cardtype', 'maxseat', 'gradecards', 'others', 'zhucards', + 'playproc', 'pushlist', 'touxiang']; sent.length = 0; EQW_Rpc.jiaofen(60); EQW_Rpc.touxiang(); EQW_Rpc.xuanzhu(1); EQW_Rpc.maipai([1,2,3,4,5,6,7,8]); EQW_Rpc.chupai([9]);