'channels' tag now also moved to sequential FT group in pipeline; role-select.js ensures Tray.close() before turn advances so as not to obstruct next gamer selection; RoleSelectSpec.js asserrts this functionality
Some checks failed
ci/woodpecker/push/woodpecker Pipeline failed
Some checks failed
ci/woodpecker/push/woodpecker Pipeline failed
This commit is contained in:
@@ -38,6 +38,7 @@ steps:
|
|||||||
- cd ./src
|
- cd ./src
|
||||||
- python manage.py collectstatic --noinput
|
- python manage.py collectstatic --noinput
|
||||||
- python manage.py test functional_tests --tag=two-browser
|
- python manage.py test functional_tests --tag=two-browser
|
||||||
|
- python manage.py test functional_tests --tag=channels
|
||||||
when:
|
when:
|
||||||
- event: push
|
- event: push
|
||||||
|
|
||||||
@@ -56,7 +57,6 @@ steps:
|
|||||||
- cd ./src
|
- cd ./src
|
||||||
- python manage.py collectstatic --noinput
|
- python manage.py collectstatic --noinput
|
||||||
- python manage.py test functional_tests --parallel --exclude-tag=channels --exclude-tag=two-browser
|
- python manage.py test functional_tests --parallel --exclude-tag=channels --exclude-tag=two-browser
|
||||||
- python manage.py test functional_tests --tag=channels
|
|
||||||
when:
|
when:
|
||||||
- event: push
|
- event: push
|
||||||
|
|
||||||
|
|||||||
@@ -163,6 +163,9 @@ var RoleSelect = (function () {
|
|||||||
var invSlot = document.getElementById("id_inv_role_card");
|
var invSlot = document.getElementById("id_inv_role_card");
|
||||||
if (invSlot) invSlot.innerHTML = "";
|
if (invSlot) invSlot.innerHTML = "";
|
||||||
|
|
||||||
|
// Close tray so it doesn't obscure the next player's card-stack
|
||||||
|
if (typeof Tray !== "undefined") Tray.close();
|
||||||
|
|
||||||
var stack = document.querySelector(".card-stack[data-user-slots]");
|
var stack = document.querySelector(".card-stack[data-user-slots]");
|
||||||
if (stack) {
|
if (stack) {
|
||||||
// Sync starter-roles from server so the fan reflects actual DB state
|
// Sync starter-roles from server so the fan reflects actual DB state
|
||||||
|
|||||||
@@ -188,6 +188,14 @@ describe("RoleSelect", () => {
|
|||||||
testDiv.appendChild(stack);
|
testDiv.appendChild(stack);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
it("calls Tray.close() on turn change", () => {
|
||||||
|
spyOn(Tray, "close");
|
||||||
|
window.dispatchEvent(new CustomEvent("room:turn_changed", {
|
||||||
|
detail: { active_slot: 2 }
|
||||||
|
}));
|
||||||
|
expect(Tray.close).toHaveBeenCalled();
|
||||||
|
});
|
||||||
|
|
||||||
it("moves .active to the newly active seat", () => {
|
it("moves .active to the newly active seat", () => {
|
||||||
window.dispatchEvent(new CustomEvent("room:turn_changed", {
|
window.dispatchEvent(new CustomEvent("room:turn_changed", {
|
||||||
detail: { active_slot: 2 }
|
detail: { active_slot: 2 }
|
||||||
|
|||||||
Reference in New Issue
Block a user