feat(utils,templates,docs): file-based .tmpl templates; remove I/O fixtures

This commit is contained in:
2025-09-12 09:56:37 +08:00
parent d724a5fb65
commit 9ff736e11c
10 changed files with 0 additions and 27 deletions

View File

@@ -62,8 +62,6 @@ problems/NNNN-name/
├── SolutionTests.cs # xUnit 測試 ├── SolutionTests.cs # xUnit 測試
├── TestProject.csproj ├── TestProject.csproj
├── main_test.go # Go testing ├── main_test.go # Go testing
├── input1.txt / output1.txt
├── input2.txt / output2.txt
├── edge_cases.md ├── edge_cases.md
└── run_tests.sh # 一鍵執行 C# 與 Go 測試 └── run_tests.sh # 一鍵執行 C# 與 Go 測試
``` ```

View File

@@ -1,2 +0,0 @@
# 測試案例 1 輸入42 Answer To Everything

View File

@@ -1,2 +0,0 @@
# 測試案例 2 輸入42 Answer To Everything

View File

@@ -1,2 +0,0 @@
# 測試案例 1 期望輸出42 Answer To Everything

View File

@@ -1,2 +0,0 @@
# 測試案例 2 期望輸出42 Answer To Everything

View File

@@ -1,2 +0,0 @@
# 測試案例 1 輸入({{NUMBER}} {{NAME_TITLE}}

View File

@@ -1,2 +0,0 @@
# 測試案例 2 輸入({{NUMBER}} {{NAME_TITLE}}

View File

@@ -1,2 +0,0 @@
# 測試案例 1 期望輸出({{NUMBER}} {{NAME_TITLE}}

View File

@@ -1,2 +0,0 @@
# 測試案例 2 期望輸出({{NUMBER}} {{NAME_TITLE}}

View File

@@ -71,15 +71,6 @@ create_test_files() {
"$problem_dir/test/edge_cases.md" \ "$problem_dir/test/edge_cases.md" \
"$number" "$number_pad" "$name_slug" "$name_title" "$difficulty" "$today" "$year_month" "$number" "$number_pad" "$name_slug" "$name_title" "$difficulty" "$today" "$year_month"
render_template "$TEMPLATES_DIR/problem/test/input1.txt.tmpl" "$problem_dir/test/input1.txt" \
"$number" "$number_pad" "$name_slug" "$name_title" "$difficulty" "$today" "$year_month"
render_template "$TEMPLATES_DIR/problem/test/output1.txt.tmpl" "$problem_dir/test/output1.txt" \
"$number" "$number_pad" "$name_slug" "$name_title" "$difficulty" "$today" "$year_month"
render_template "$TEMPLATES_DIR/problem/test/input2.txt.tmpl" "$problem_dir/test/input2.txt" \
"$number" "$number_pad" "$name_slug" "$name_title" "$difficulty" "$today" "$year_month"
render_template "$TEMPLATES_DIR/problem/test/output2.txt.tmpl" "$problem_dir/test/output2.txt" \
"$number" "$number_pad" "$name_slug" "$name_title" "$difficulty" "$today" "$year_month"
render_template "$TEMPLATES_DIR/problem/test/run_tests.sh.tmpl" \ render_template "$TEMPLATES_DIR/problem/test/run_tests.sh.tmpl" \
"$problem_dir/test/run_tests.sh" \ "$problem_dir/test/run_tests.sh" \
"$number" "$number_pad" "$name_slug" "$name_title" "$difficulty" "$today" "$year_month" "$number" "$number_pad" "$name_slug" "$name_title" "$difficulty" "$today" "$year_month"