mirror of
https://github.com/kuhyx/testsAndMisc.git
synced 2026-11-11 12:07:52 +01:00
github.com/kuhyx/mtk-root
Unlike the app extractions, mtk_root could not travel alone: its four
libraries and three of its four test suites sat in scripts/lib/, one
directory up from the stages that source them. Taking only the directory
would have orphaned eight files here and left the new repo unable to
source anything, so all twelve moved in one filter-repo pass. The
mtk_root/ + lib/ sibling layout is preserved, so every
`source "$SCRIPT_DIR/../lib/..."` resolves with no call site edited.
Two things the new repo needed that the monorepo provided implicitly:
lib/tests/run_all.sh -- the copy here is shared with the non-mtk suite
and stays. Without a new one, shell-tests.yml's
glob over */lib/tests/run_all.sh would have
stopped covering these suites on a green build.
.shellcheckrc -- external-sources + source-path=SCRIPTDIR, which
is what lets shellcheck run with no severity
filter and still pass on the ../lib/ sources.
mtk_harness.sh stays here despite the name: test_common_datetime.sh
sources it. Removing it broke that suite outright, which running the
suite caught immediately. Its header now describes what it actually
serves; the misleading name is kept on purpose, since renaming would
churn its one consumer for nothing.
Verified: 84 tests pass in the new repo with shellcheck clean, 55 still
pass here, and check_shell_coverage.sh --all exits 0 with the four
mtk_root allowlist entries gone.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01PJrqKERAo5QUeEHWS5Asgp
21 lines
1.8 KiB
JSON
21 lines
1.8 KiB
JSON
{
|
|
"title": "Extract mtk_root together with the libraries that live outside it",
|
|
"objective": "Move the MediaTek rooting toolkit to its own public repo. Unlike the three app extractions, mtk_root's libraries and half its test suites live in linux_configuration/scripts/lib/, one directory up. Extracting the directory alone would orphan eight files here and leave the new repo unable to source anything.",
|
|
"acceptance_criteria": [
|
|
"The new repo preserves the mtk_root/ + lib/ sibling layout, so every `source \"$SCRIPT_DIR/../lib/...\"` resolves without editing a single call site.",
|
|
"All 84 mtk tests pass from a clean clone of the new repo.",
|
|
"shellcheck exits 0 over every script in the new repo with no severity filter, which requires carrying .shellcheckrc across.",
|
|
"The new repo has its own lib/tests/run_all.sh, because the monorepo's is shared with a non-mtk suite and must stay.",
|
|
"The suite remaining in the monorepo still passes: removing a shared fixture must not take test_common_datetime.sh down with it.",
|
|
"meta/shell-coverage-allowlist.txt has no entry naming a removed path.",
|
|
"check_shell_coverage.sh --all exits 0.",
|
|
"pre-commit passes without --no-verify."
|
|
],
|
|
"out_of_scope": [
|
|
"single_use/utils/lib/bl9000_*.sh, which is separate Android rooting tooling that merely mentions mtkclient.",
|
|
"Renaming mtk_harness.sh, whose name is now historical but whose one consumer would churn for no behavioural gain.",
|
|
"Verifying the toolkit against real hardware, which READY.md already records as pending."
|
|
],
|
|
"verifier": "./lib/tests/run_all.sh in the new repo reports 84 passed / 0 failed; shellcheck over the new repo exits 0; ./linux_configuration/scripts/lib/tests/run_all.sh here reports 55 passed / 0 failed; bash meta/scripts/check_shell_coverage.sh --all exits 0; gh confirms the repo is public on main."
|
|
}
|