🔧 chore(ci): automate superpowers sync workflow
Update Third-party Superpowers / Update thirdparty/skill snapshot (push) Successful in 1m19s
Details
Update Third-party Superpowers / Update thirdparty/skill snapshot (push) Successful in 1m19s
Details
run the thirdparty superpowers snapshot updater on a daily schedule. trigger sync-superpowers automatically when thirdparty/skill is updated and cover the new automation with workflow tests.
This commit is contained in:
parent
eaaa39c39b
commit
51373d7469
|
|
@ -1,6 +1,9 @@
|
|||
name: Sync Superpowers Skills
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- thirdparty/skill
|
||||
workflow_dispatch:
|
||||
|
||||
concurrency:
|
||||
|
|
|
|||
|
|
@ -5,6 +5,8 @@ on:
|
|||
branches:
|
||||
- main
|
||||
workflow_dispatch:
|
||||
schedule:
|
||||
- cron: "@daily"
|
||||
|
||||
concurrency:
|
||||
group: thirdparty-superpowers-update-${{ github.repository }}
|
||||
|
|
|
|||
|
|
@ -13,6 +13,11 @@ class SuperpowersWorkflowTests(unittest.TestCase):
|
|||
text = SYNC_WORKFLOW.read_text(encoding="utf-8")
|
||||
self.assertIn("workflow_dispatch:", text)
|
||||
|
||||
def test_sync_workflow_triggers_on_thirdparty_push(self):
|
||||
text = SYNC_WORKFLOW.read_text(encoding="utf-8")
|
||||
self.assertIn("push:", text)
|
||||
self.assertIn("- thirdparty/skill", text)
|
||||
|
||||
def test_sync_workflow_clears_stale_index_flags(self):
|
||||
text = SYNC_WORKFLOW.read_text(encoding="utf-8")
|
||||
self.assertIn("git update-index --no-assume-unchanged", text)
|
||||
|
|
@ -33,6 +38,11 @@ class SuperpowersWorkflowTests(unittest.TestCase):
|
|||
self.assertIn("- main", text)
|
||||
self.assertIn("workflow_dispatch:", text)
|
||||
|
||||
def test_auto_update_workflow_runs_daily_schedule(self):
|
||||
text = AUTO_UPDATE_WORKFLOW.read_text(encoding="utf-8")
|
||||
self.assertIn("schedule:", text)
|
||||
self.assertIn('- cron: "@daily"', text)
|
||||
|
||||
def test_auto_update_workflow_runs_update_script(self):
|
||||
text = AUTO_UPDATE_WORKFLOW.read_text(encoding="utf-8")
|
||||
self.assertIn("bash .gitea/ci/update_thirdparty_superpowers.sh", text)
|
||||
|
|
|
|||
Loading…
Reference in New Issue