本文整理匯總了TypeScript中poker/appconfig.overrideConfiguration函數的典型用法代碼示例。如果您正苦於以下問題:TypeScript overrideConfiguration函數的具體用法?TypeScript overrideConfiguration怎麽用?TypeScript overrideConfiguration使用的例子?那麽, 這裏精選的函數代碼示例或許可以為您提供幫助。
在下文中一共展示了overrideConfiguration函數的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的TypeScript代碼示例。
示例1: beforeAll
beforeAll(() => {
overrideConfiguration({
game: {
cardsOverlaySupported: true,
},
});
});
示例2: it
it("Confguration override work with game settings override", function () {
overrideConfiguration({
game: {
noTableMoneyLimit: false,
},
});
expect(appConfig.game.noTableMoneyLimit).toEqual(false);
expect(appConfig.game.autoFoldAsFoldOnRaise).toEqual(true);
expect(appConfig.game.handHistory).toBeDefined();
});
示例3: it
it("Overlay is not needed if not supported", function () {
overrideConfiguration({
game: {
cardsOverlaySupported: false,
},
});
const tableView = new TableView(1, {
TableId: 1,
TableName: "",
BigBlind: 200,
SmallBlind: 100,
CurrencyId: 1,
HandsPerHour: 0,
AveragePotSize: 0,
JoinedPlayers: 2,
MaxPlayers: 8,
PotLimitType: 2,
}, noopApiProvider);
const players: GamePlayerStartInformation[] = [{
PlayerId: 1,
Money: 10000,
}, {
PlayerId: 2,
Money: 10000,
}];
const actions: GameActionStartInformation[] = [];
login("player1");
loginId(1);
authenticated(true);
const tableSatusPlayers = [
getSeatPlayer(1, 10000),
getSeatPlayer(2, 10000),
];
tableView.onTableStatusInfo(tableSatusPlayers, [], null, 4, 100, 10, null, null, null, null, 1, true, 0, false, true, null, 0, 2);
tableView.onGameStarted(1, players, actions, 4);
tableView.onBet(2, 0, 100, 1);
tableView.onBet(1, 0, 200, 2);
tableView.onPlayerCards(1, [15, 5, 41, 18]);
tableView.onPlayerCards(2, [1, 2, 3, 4]);
tableView.onBet(2, 2, 50, 1);
tableView.onBet(1, 2, 50, 1);
expect(tableView.tablePlaces.place1().needCardsOverlay()).toEqual(false);
expect(tableView.tablePlaces.place2().needCardsOverlay()).toEqual(false);
});
示例4: it
it(`Does not collapse it when collapse setting is ${settingStatus} and ${expandedStatus}`, function () {
const actionBlock = new ActionBlock();
setupTestSlider(actionBlock);
setupInGamePlayer(actionBlock);
overrideConfiguration({
game: {
collapseRaiseBlockWhenExpanded: definition.collapseRaiseBlockWhenExpanded,
},
});
actionBlock.checkOrCallAmount(100);
actionBlock.callAmount(100);
actionBlock.playerMoney(1000);
actionBlock.maxAmountOfMoneyForOtherActivePlayers(10000);
actionBlock.expanded(definition.expanded);
expect(actionBlock.raiseBlockVisible()).toEqual(true);
expect(actionBlock.raiseBlockCollapsed()).toEqual(definition.collapsed);
});