fixes to kit bag dialog & mini-tooltip presence which stymied a pair of FTs
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
This commit is contained in:
@@ -41,10 +41,9 @@ class CarteBlancheTest(FunctionalTest):
|
||||
f'#id_kit_bag_dialog [data-token-type="{Token.PASS}"]',
|
||||
)
|
||||
)
|
||||
# 3. Navigate to gameboard
|
||||
self.browser.find_element(
|
||||
By.CSS_SELECTOR, '#id_footer_nav a[href="/gameboard/"]'
|
||||
).click()
|
||||
# 3. Navigate to gameboard (use get() — kit bag dialog still open and
|
||||
# would intercept a click on the footer nav link in headless Firefox)
|
||||
self.browser.get(self.live_server_url + "/gameboard/")
|
||||
self.wait_for(
|
||||
lambda: self.assertRegex(self.browser.current_url, r"/gameboard/$")
|
||||
)
|
||||
@@ -86,16 +85,26 @@ class CarteBlancheTest(FunctionalTest):
|
||||
self.browser.get(self.live_server_url + "/gameboard/")
|
||||
self.wait_for(lambda: self.browser.find_element(By.ID, "id_game_kit"))
|
||||
|
||||
# 2. Hover over Coin-on-a-String, Free Token — no mini tooltip (not equippable)
|
||||
for token_id in ("id_kit_coin_on_a_string", "id_kit_free_token"):
|
||||
el = self.browser.find_element(By.ID, token_id)
|
||||
ActionChains(self.browser).move_to_element(el).perform()
|
||||
self.wait_for(
|
||||
lambda: self.browser.find_element(By.ID, "id_tooltip_portal").is_displayed()
|
||||
)
|
||||
self.assertFalse(
|
||||
# 2. Hover over Free Token — no mini tooltip (not a trinket, no data-token-id)
|
||||
el = self.browser.find_element(By.ID, "id_kit_free_token")
|
||||
ActionChains(self.browser).move_to_element(el).perform()
|
||||
self.wait_for(
|
||||
lambda: self.browser.find_element(By.ID, "id_tooltip_portal").is_displayed()
|
||||
)
|
||||
self.assertFalse(
|
||||
self.browser.find_element(By.ID, "id_mini_tooltip_portal").is_displayed()
|
||||
)
|
||||
# Coin-on-a-String IS equippable (has data-token-id) — mini tooltip shows
|
||||
coin_el = self.browser.find_element(By.ID, "id_kit_coin_on_a_string")
|
||||
ActionChains(self.browser).move_to_element(coin_el).perform()
|
||||
self.wait_for(
|
||||
lambda: self.browser.find_element(By.ID, "id_tooltip_portal").is_displayed()
|
||||
)
|
||||
self.wait_for(
|
||||
lambda: self.assertTrue(
|
||||
self.browser.find_element(By.ID, "id_mini_tooltip_portal").is_displayed()
|
||||
)
|
||||
)
|
||||
|
||||
# 3. Hover Carte Blanche — main tooltip present; mini tooltip shows "Equip Trinket?"
|
||||
carte_el = self.browser.find_element(By.ID, "id_kit_carte_blanche")
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<div id="id_room_menu" style="display:none">
|
||||
<a href="/gameboard/" class="btn btn-cancel">EXIT</a>
|
||||
<a href="/gameboard/" class="btn btn-cancel">NVM</a>
|
||||
{% if request.user == room.owner %}
|
||||
<form method="POST" action="{% url 'epic:delete_room' room.id %}">
|
||||
{% csrf_token %}
|
||||
|
||||
Reference in New Issue
Block a user