rename natus → sky across the codebase — natal chart abstraction is now sky throughout, since chart inputs aren't birthday-gated
Some checks failed
ci/woodpecker/push/pyswiss Pipeline was successful
ci/woodpecker/push/main Pipeline failed

Mechanical rename: 5 files (sky-wheel.js, _sky.scss, _sky_overlay.html, SkyWheelSpec.js x2), 24 in-place edits across templates/views/urls/SCSS/JS/tests/CLAUDE.md. URL names epic:natus_save → epic:sky_save (epic namespaced, no clash w. dashboard:sky_save), JS module NatusWheel → SkyWheel, DOM ids id_natus_* → id_sky_*, BEM classes natus-* → sky-*, dashboard sky_natus_data/sky_natus_preview collapsed to sky_data/sky_preview_data. No DB migration needed (User.sky_chart_data + GameEvent.SKY_SAVED already used sky-prefix). 778 ITs + Jasmine green.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
Disco DeDisco
2026-05-04 20:36:15 -04:00
parent 19b7828ea9
commit cc2a3f3526
29 changed files with 338 additions and 338 deletions

View File

@@ -119,7 +119,7 @@ class StargazerNoteFromDashboardTest(FunctionalTest):
self.browser.get(self.live_server_url)
confirm_btn = self.wait_for(
lambda: self.browser.find_element(By.ID, "id_natus_confirm")
lambda: self.browser.find_element(By.ID, "id_sky_confirm")
)
self.assertIsNotNone(confirm_btn.get_attribute("disabled"))
self.assertFalse(self.browser.find_elements(By.CSS_SELECTOR, ".note-banner"))
@@ -136,7 +136,7 @@ class StargazerNoteFromDashboardTest(FunctionalTest):
self.browser.execute_script(_mock_preview_js(_CHART_FIXTURE))
_fill_valid_sky_form(self.browser)
confirm_btn = self.browser.find_element(By.ID, "id_natus_confirm")
confirm_btn = self.browser.find_element(By.ID, "id_sky_confirm")
self.wait_for(lambda: self.assertIsNone(confirm_btn.get_attribute("disabled")))
confirm_btn.click()
@@ -338,7 +338,7 @@ class StargazerNoteFromSkyPageTest(FunctionalTest):
self.browser.get(self.sky_url)
confirm_btn = self.wait_for(
lambda: self.browser.find_element(By.ID, "id_natus_confirm")
lambda: self.browser.find_element(By.ID, "id_sky_confirm")
)
self.assertIsNotNone(confirm_btn.get_attribute("disabled"))
self.assertFalse(self.browser.find_elements(By.CSS_SELECTOR, ".note-banner"))
@@ -351,11 +351,11 @@ class StargazerNoteFromSkyPageTest(FunctionalTest):
self.create_pre_authenticated_session("stargazer@test.io")
self.browser.get(self.sky_url)
self.wait_for(lambda: self.browser.find_element(By.ID, "id_natus_confirm"))
self.wait_for(lambda: self.browser.find_element(By.ID, "id_sky_confirm"))
self.browser.execute_script(_mock_preview_js(_CHART_FIXTURE))
_fill_valid_sky_form(self.browser)
confirm_btn = self.browser.find_element(By.ID, "id_natus_confirm")
confirm_btn = self.browser.find_element(By.ID, "id_sky_confirm")
self.wait_for(lambda: self.assertIsNone(confirm_btn.get_attribute("disabled")))
confirm_btn.click()
@@ -386,11 +386,11 @@ class StargazerNoteFromSkyPageTest(FunctionalTest):
self.create_pre_authenticated_session("stargazer@test.io")
self.browser.get(self.sky_url)
self.wait_for(lambda: self.browser.find_element(By.ID, "id_natus_confirm"))
self.wait_for(lambda: self.browser.find_element(By.ID, "id_sky_confirm"))
self.browser.execute_script(_mock_preview_js(_CHART_FIXTURE))
_fill_valid_sky_form(self.browser)
confirm_btn = self.browser.find_element(By.ID, "id_natus_confirm")
confirm_btn = self.browser.find_element(By.ID, "id_sky_confirm")
self.wait_for(lambda: self.assertIsNone(confirm_btn.get_attribute("disabled")))
confirm_btn.click()

View File

@@ -1,7 +1,7 @@
"""Functional tests for the My Sky dashboard feature.
My Sky is a dashboard applet linking to /dashboard/sky/ — a full-page
natus (natal chart) interface where the user can save their personal sky
sky (natal chart) interface where the user can save their personal sky
to their account (stored on the User model, independent of any game room).
"""
@@ -61,7 +61,7 @@ class MySkyAppletTest(FunctionalTest):
def test_my_sky_applet_links_to_sky_page_with_form(self):
"""Applet is visible on dashboard; link leads to /dashboard/sky/ with
all natus form fields present."""
all sky form fields present."""
self.create_pre_authenticated_session("stargazer@test.io")
self.browser.get(self.live_server_url)
@@ -80,14 +80,14 @@ class MySkyAppletTest(FunctionalTest):
lambda: self.assertRegex(self.browser.current_url, r"/dashboard/sky/$")
)
# 4. All natus form fields are present
# 4. All sky form fields are present
self.browser.find_element(By.ID, "id_nf_date")
self.browser.find_element(By.ID, "id_nf_time")
self.browser.find_element(By.ID, "id_nf_place")
self.browser.find_element(By.ID, "id_nf_lat")
self.browser.find_element(By.ID, "id_nf_lon")
self.browser.find_element(By.ID, "id_nf_tz")
self.browser.find_element(By.ID, "id_natus_confirm")
self.browser.find_element(By.ID, "id_sky_confirm")
class MySkyLocalStorageTest(FunctionalTest):
@@ -171,7 +171,7 @@ class MySkyAppletWheelTest(FunctionalTest):
def test_saved_sky_wheel_renders_with_element_tooltip_in_applet(self):
"""When the user has saved sky data, the natal wheel appears in the My Sky
applet and clicking an element-ring slice shows the tooltip.
(Planet click tooltip is covered by NatusWheelSpec.js T3/T4/T5.)"""
(Planet click tooltip is covered by SkyWheelSpec.js T3/T4/T5.)"""
self.create_pre_authenticated_session("stargazer@test.io")
self.browser.get(self.live_server_url)
@@ -192,14 +192,14 @@ class MySkyAppletWheelTest(FunctionalTest):
slice_el,
)
self.wait_for(lambda: self.assertEqual(
self.browser.find_element(By.ID, "id_natus_tooltip")
self.browser.find_element(By.ID, "id_sky_tooltip")
.value_of_css_property("display"),
"block",
))
class MySkyAppletFormTest(FunctionalTest):
"""My Sky applet shows natus entry form when no sky data is saved."""
"""My Sky applet shows sky entry form when no sky data is saved."""
def setUp(self):
super().setUp()
@@ -212,7 +212,7 @@ class MySkyAppletFormTest(FunctionalTest):
# ── T4 ───────────────────────────────────────────────────────────────────
def test_applet_shows_entry_form_when_no_sky_saved(self):
"""When no sky data is saved the My Sky applet shows all natus form
"""When no sky data is saved the My Sky applet shows all sky form
fields and a disabled SAVE SKY button; no wheel is drawn yet."""
self.create_pre_authenticated_session("stargazer@test.io")
self.browser.get(self.live_server_url)
@@ -227,7 +227,7 @@ class MySkyAppletFormTest(FunctionalTest):
applet.find_element(By.ID, "id_nf_lat")
applet.find_element(By.ID, "id_nf_lon")
applet.find_element(By.ID, "id_nf_tz")
applet.find_element(By.ID, "id_natus_confirm")
applet.find_element(By.ID, "id_sky_confirm")
self.assertFalse(applet.find_elements(By.CSS_SELECTOR, ".nw-root"))
@@ -276,7 +276,7 @@ class MySkyAppletFormTest(FunctionalTest):
""")
# Wait for confirm button to be enabled (preview resolved)
confirm_btn = self.browser.find_element(By.ID, "id_natus_confirm")
confirm_btn = self.browser.find_element(By.ID, "id_sky_confirm")
self.wait_for(lambda: self.assertIsNone(
confirm_btn.get_attribute("disabled")
))
@@ -331,4 +331,4 @@ class MySkyWheelConjunctionTest(FunctionalTest):
))
# (T7 tick-extends-past-zodiac, T8 click-raises-to-front, and T9c/T9n/T9w
# cycle navigation are covered by NatusWheelSpec.js.)
# cycle navigation are covered by SkyWheelSpec.js.)

View File

@@ -38,7 +38,7 @@ def _make_sky_confirmed_room(live_server_url, user, earthman):
@tag("channels")
class PickSeaAsyncTransitionTest(ChannelsFunctionalTest):
"""After sky confirm, the natus overlay closes and the room reloads to the
"""After sky confirm, the sky overlay closes and the room reloads to the
table hex w. the PICK SEA btn visible — the gamer must opt into the sea
overlay rather than be auto-launched into it."""
@@ -66,19 +66,19 @@ class PickSeaAsyncTransitionTest(ChannelsFunctionalTest):
self.room_url = self.live_server_url + reverse(
"epic:room", kwargs={"room_id": self.room.id}
)
self.natus_save_url = self.live_server_url + reverse(
"epic:natus_save", kwargs={"room_id": self.room.id}
self.sky_save_url = self.live_server_url + reverse(
"epic:sky_save", kwargs={"room_id": self.room.id}
)
def _confirm_sky(self):
"""POST to natus_save with action=confirm from browser JS (bypasses chart form)."""
"""POST to sky_save with action=confirm from browser JS (bypasses chart form)."""
# Wait for the room WS connection to be ready before triggering confirm
self.wait_for(lambda: self.browser.execute_script(
"return !!(window._roomSocket && window._roomSocket.readyState === 1);"
))
self.browser.execute_script(f"""
const csrf = (document.cookie.match(/csrftoken=([^;]+)/) || ['',''])[1];
fetch('{self.natus_save_url}', {{
fetch('{self.sky_save_url}', {{
method: 'POST',
credentials: 'same-origin',
headers: {{'Content-Type': 'application/json', 'X-CSRFToken': csrf}},
@@ -113,8 +113,8 @@ class PickSeaAsyncTransitionTest(ChannelsFunctionalTest):
)
self.assertFalse(has_sea_open)
def test_natus_overlay_closed_after_sky_confirm(self):
"""Natus overlay is gone (page reloaded) after sky confirm."""
def test_sky_overlay_closed_after_sky_confirm(self):
"""Sky overlay is gone (page reloaded) after sky confirm."""
self.create_pre_authenticated_session("founder@test.io")
self.browser.get(self.room_url)
self.wait_for(lambda: self.browser.find_element(By.ID, "id_pick_sky_btn"))
@@ -122,8 +122,8 @@ class PickSeaAsyncTransitionTest(ChannelsFunctionalTest):
self._confirm_sky()
self.wait_for(lambda: self.browser.find_element(By.ID, "id_pick_sea_btn"))
natus = self.browser.find_elements(By.ID, "id_natus_overlay")
self.assertTrue(not natus or not natus[0].is_displayed())
sky = self.browser.find_elements(By.ID, "id_sky_overlay")
self.assertTrue(not sky or not sky[0].is_displayed())
def test_clicking_pick_sea_btn_opens_sea_overlay(self):
"""The gamer's explicit click on PICK SEA is what opens the sea overlay."""

View File

@@ -46,7 +46,7 @@ class PickSkyLocalStorageTest(FunctionalTest):
)
self.browser.execute_script("arguments[0].click()", btn)
self.wait_for(
lambda: self.browser.find_element(By.ID, "id_natus_overlay")
lambda: self.browser.find_element(By.ID, "id_sky_overlay")
)
def _fill_form(self):
@@ -89,7 +89,7 @@ class PickSkyLocalStorageTest(FunctionalTest):
self._fill_form()
# Close via NVM
self.browser.find_element(By.ID, "id_natus_cancel").click()
self.browser.find_element(By.ID, "id_sky_cancel").click()
# Reopen
self._open_overlay()

View File

@@ -27,7 +27,7 @@ from apps.lyric.models import User
# - On page reload: tray always starts closed (JS in-memory only).
#
# Contents (populated in later sprints): Role card, Significator, Celtic Cross
# draw, natus wheel, committed dice/cards for this table.
# draw, sky wheel, committed dice/cards for this table.
#
# ─────────────────────────────────────────────────────────────────────────────