brainstorming
brainstorming
You MUST use this before any creative work - creating features, building components, adding functionality, modifying behavior, or planning anything new, in software or out of it (a talk, a business, a renovation).
run-puzzle-testsRun the jigsawR test suite via WSL R execution. Supports full suite, filtered by pattern, or single file. Interprets pass/fail/skip counts and identifies failing tests. Never uses --vanilla flag (renv needs .Rprofile for activation). Use after modifying any R source code, after adding a new puzzle type or feature, before committing changes to verify nothing…
Independent GitHub snapshot · Automated classification · Original documentation governs
行 jigsawR 測組釋果。
full、filtered、single)filtered 模,如 "snic"、"rectangular")single 模)| 範 | 用時 | 久 |
|---|---|---|
| 全 | 提前、大改後 | ~2-5 分 |
| 濾 | 一拼類工 | ~30 秒 |
| 單 | 除特測 | ~10 秒 |
得:按工選範—提前用全、特類用濾、除錯用單。
敗:未定→默全。久而捕跨類退。
全組:
建本檔(如 /tmp/run_tests.R):
devtools::test()
R_EXE="/mnt/c/Program Files/R/R-4.5.0/bin/Rscript.exe"
cd /mnt/d/dev/p/jigsawR && "$R_EXE" -e "devtools::test()"
濾:
"$R_EXE" -e "devtools::test(filter = 'snic')"
單檔:
"$R_EXE" -e "testthat::test_file('tests/testthat/test-snic-puzzles.R')"
得:測出含過/敗/跳。
敗:
--vanilla;renv 需 .Rprofile 啟renv::restore()求總行:
[ FAIL 0 | WARN 0 | SKIP 7 | PASS 2042 ]
snic)得:總行解 PASS、FAIL、SKIP、WARN。FAIL = 0 為清。
敗:總行不見→測器或於完前崩。察上 R 級誤。出截→重定至檔:"$R_EXE" -e "devtools::test()" > test_results.txt 2>&1。
若敗:
# Run just the failing test with verbose output
"$R_EXE" -e "testthat::test_file('tests/testthat/test-failing.R', reporter = 'summary')"
得:諸敗本因明。或為退(碼修)或為境問題(缺依、徑)。
敗:訊不明→測中加 browser()/print()、testthat::test_file() 互動除。
跳於缺可選依為常:
snic 包測跳於 skip_if_not_installed("snic")skip_on_os()skip_on_cran()確跳因正當、非藏真敗。
得:諸跳有正因(可選不裝、平台、僅 CRAN)。無跳藏實敗。
敗:跳可疑→暫除 skip_if_*()、行測察過或露藏敗。
--vanilla:破 renv 啟。jigsawR 永勿用-e 串:殼義漏致 Exit 5。用本檔devtools::load_all() 或 devtools::document()DESCRIPTION Suggeststestthat::test_file()generate-puzzleadd-puzzle-typewrite-testthat-testsvalidate-piles-notation