Repository navigation
Task Issue 999 Delete Legacy ArchiveData TestProject
Status: implemented on task/issue-999, verified locally against the repo's
MariaDB fixture (127.0.0.1:3307) and PHP 8.4.28 built-in server
(http://127.0.0.1:8083). Prerequisites #994–#998 are all CLOSED/COMPLETED.
Issue #999 still described lib/testcases/archiveData.php as a 1.9.20
controller with a case testproject: branch at lines 41–57. That code no
longer exists: commits 36783cb57 / 66b9d0b8f (issue #1536, CLOSED)
replaced the entire controller with a 20-line redirect stub. The PHP half of
this cleanup was therefore already done — but the stub sent every deep
link to testcases/tcEdit.html, including edit=testproject, which is the
wrong modern twin.
What survived was the legacy Smarty viewer:
| Artifact | State before #999 |
|---|---|
gui/templates/dashio/testcases/include/testprojectView.inc.tpl |
79-line testproject-only operations panel + name/notes table; zero {include} sites anywhere in PHP/TPL/JS |
gui/templates/dashio/testcases/containerView.tpl |
level == 'testproject' block (operations panel, name/notes table, lib/project/projectView.php link) still rendered by testproject::show()
|
gui/templates/tl-classic/testcases/containerView.tpl |
dead-theme twin of the same block (precedent #984/#966/#992 retires both theme copies) |
lib/functions/testproject.class.php::show() |
still built the full legacy GUI object and displayed containerView.tpl for 4 remaining call sites in lib/testcases/containerEdit.php (file upload, file delete, suite reorder, suite move) |
-
lib/testcases/archiveData.php—edit=testprojectdeep links now go togui/templates/projects/projectInfoView.html?tproject_id=<id>; test-case deep links still go totcEdit.htmlunchanged. -
lib/functions/testproject.class.php::show()— converted from the legacy Smarty renderer to a documented compatibility shim that redirects the 4 surviving callers toprojectInfoView.html. No caller edits were needed. -
gui/templates/dashio/testcases/containerView.tpl— removed thelevel == 'testproject'branch and the project-only URL assignments (importToTProjectAction,testSpecFullDocAction,testSpecFullWordDocAction). Thetestsuitebranch and shared attachments include are untouched. -
gui/templates/dashio/testcases/include/testprojectView.inc.tpl— DELETED. -
gui/templates/tl-classic/testcases/containerView.tpl— same testproject block and project-only URLs removed in the unused classic theme. - Docs/CHANGELOG/
SCREEN-COMPARE-STATUS.mdrow 66, screenshot and test suite updated below.
Deliberately kept: archiveData.php itself (still the #1536 redirect stub for
test-case deep links), testsuite.class.php::show(), the testsuite branch of
both containerView.tpl files, attachments.inc.tpl, and all modern BFF
routes. No locale/config section becomes orphaned by this cleanup.
-
php -lclean onlib/testcases/archiveData.phpandlib/functions/testproject.class.php. - Smarty compile harness (real
TLSmarty+lang_getplugin): dashiotestcases/containerView.tplcompiles OK after the edit. The classic twin compiles up to its pre-existingattachments.inc.tpl:102syntax error, which is unrelated to this change and already present on the base branch. -
grep -rn 'testprojectView.inc.tpl'→ only the deletion record in Git/docs; zero runtime inclusion.importToTProjectAction/testSpecFull*no longer exist in eithercontainerView.tpl(only parity comments in the modern screen remain). - HTTP with an authenticated admin session:
-
archiveData.php?edit=testproject&id=1→ 302 toprojectInfoView.html?tproject_id=1(previously →tcEdit.html?tcase_id=1). -
archiveData.php?edit=testcase&id=4&tproject_id=1→ 302 totcEdit.html?doAction=edit&tcase_id=4&tproject_id=1&tplan_id=0(unchanged). - Legacy
containerEdit.php?doAction=reorder_testproject_testsuites_alpha&containerID=<fixture>→ 200 withlocation.href='.../projectInfoView.html?tproject_id=<fixture>'and no Smarty fatal. - Temporary BFF fixture
ZZ999CleanupProbe(id 1901) and suite fixtureZZ999SuiteProbe(id 1902) were deleted afterwards; 0 rows remain.
-
- Browser (headless Chromium via chrome-devtools MCP):
projectInfoView.htmlrenders the modern Test Project Information screen with the #994–#998 toolbar (New Test Suite / Reorder A-Z / Export all / Import / Generate Test Spec HTML + Word), Overview, Description, Integrations and Test Suites table. Console shows only the pre-existing generic label/for warning. Screenshot:docs/screenshots/issue-999-projectinfo-after-cleanup.png. - Event Viewer: all rows created during the test window are
log_level=16(AUDIT); 0 Error, 0 Warning.
cd /home/sebi/testlink
git checkout task/issue-999
php -S 127.0.0.1:8083 -t . &
# login admin/admin, then:
curl -s -o /dev/null -w '%{http_code} %{redirect_url}\n' \
'http://127.0.0.1:8083/lib/testcases/archiveData.php?edit=testproject&id=1'
# 302 -> /gui/templates/projects/projectInfoView.html?tproject_id=1