mirror of
https://github.com/AlecM33/Werewolf.git
synced 2025-12-26 15:57:50 +01:00
lint, add spec, add info button to added roles
This commit is contained in:
@@ -104,5 +104,20 @@ describe('Create page', function () {
|
||||
expect(gameCreationStepManager.deckManager.deck.length).toEqual(5);
|
||||
expect(document.querySelectorAll('.added-role').length).toEqual(5);
|
||||
});
|
||||
|
||||
it('clear existing added cards and leave only what roles are part of the template', () => {
|
||||
document.getElementById('role-category-default').click();
|
||||
const roles = document.querySelectorAll('.default-role');
|
||||
roles.forEach((el) => {
|
||||
const plusElement = el.querySelector('.role-include');
|
||||
plusElement.click();
|
||||
});
|
||||
|
||||
document.getElementById('deck-template-button').click();
|
||||
document.querySelectorAll('.template-option')[0].click();
|
||||
|
||||
expect(gameCreationStepManager.deckManager.deck.length).toEqual(5);
|
||||
expect(document.querySelectorAll('.added-role').length).toEqual(5);
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user