Skip to content

Commit 0bb9e7c

Browse files
committed
ci: Add verification test for bootstrap fix (issue #8837)
Add a CI check to verify that locale files are successfully copied during the build phase without relying on the system install command. This test ensures the bootstrap issue doesn't regress. The test verifies: - Locales directory is created - Common uucore locales are copied - Utility-specific locales are copied - A reasonable number of locale files exist (>50) This addresses the maintainer request to add a regression test for the fix.
1 parent 1670692 commit 0bb9e7c

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed

.github/workflows/CICD.yml

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -293,6 +293,30 @@ jobs:
293293
test -f target/CACHEDIR.TAG
294294
# Restore cache for target/release (we only did a debug build)
295295
mv -t target/ target.cache/release 2>/dev/null || true
296+
- name: "Verify bootstrap fix (issue #8837)"
297+
shell: bash
298+
run: |
299+
set -x
300+
# Verify that locales were successfully copied during build
301+
# This ensures the bootstrap issue is fixed - the build should work
302+
# even without relying on system 'install' command
303+
304+
echo "Checking that locale files were copied to build directory..."
305+
test -d target/debug/locales || { echo "::error ::Locales directory not created"; exit 1; }
306+
307+
# Check for uucore common locales
308+
test -f target/debug/locales/uucore/fr-FR.ftl || { echo "::error ::uucore locale not copied"; exit 1; }
309+
310+
# Check for at least a few utility-specific locales
311+
test -f target/debug/locales/ls/fr-FR.ftl || { echo "::error ::ls locale not copied"; exit 1; }
312+
test -f target/debug/locales/cat/fr-FR.ftl || { echo "::error ::cat locale not copied"; exit 1; }
313+
314+
# Count total locale files to ensure reasonable number were copied
315+
LOCALE_COUNT=$(find target/debug/locales -name "*.ftl" | wc -l)
316+
echo "Found $LOCALE_COUNT locale files"
317+
[ "$LOCALE_COUNT" -gt 50 ] || { echo "::error ::Too few locale files copied ($LOCALE_COUNT)"; exit 1; }
318+
319+
echo "Bootstrap fix verified: locales copied successfully without system install"
296320
- name: "`make nextest`"
297321
shell: bash
298322
run: make nextest CARGOFLAGS="--profile ci --hide-progress-bar"

0 commit comments

Comments
 (0)