aboutsummaryrefslogtreecommitdiffhomepage
path: root/crates/shirabe/tests/package/version/version_guesser_test.rs
AgeCommit message (Collapse)Author
2026-06-28refactor: add linternsfisis
2026-06-26test: port 44 vcs/downloader/version tests using mock infransfisis
Port git, version_guesser, gitlab_driver, github_driver, and git_downloader tests using the ProcessExecutor/HttpDownloader mocks and IO/Config stubs. Fix production regex-porting bugs surfaced by the now-reachable paths: Url::sanitize and Response::find_header_value had non-delimited PCRE patterns; implement array_search_mixed non-strict branch and a datetime format mapping. Add HttpDownloader::__new_mock so mocked downloaders skip curl construction. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-22test: un-ignore tests that now passnsfisis
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-22test: port more test casesnsfisis
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-21test(tests): expand stub macros into plain test functionsnsfisis
The per-file stub!/encode_stub!/etc. macros generated #[ignore]d test functions but obscured the individual test bodies. Expanding them inline removes the macro indirection so future ports can fill in each function directly. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-21test(tests): port setUp/tearDown as set_up/tear_down with TearDownnsfisis
Port PHP setUp/tearDown across the ported integration tests using same-named set_up()/tear_down() functions and a TearDown struct whose Drop runs tear_down(). Fixture-init setUp returns its fixtures; tmpdir-style setUp/tearDown carry state in TearDown fields. Parts that depend on unported infrastructure (PHPUnit mocks, Config::merge, the PHP error handler) stay todo!() and are only wired into ignored stubs to avoid breaking live tests. Also fix shirabe-php-shim putenv to handle the no-'=' form (PHP unsets the variable), which Platform::clear_env relies on for the env-clearing tearDowns. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-21test: port remaining repository and util tests as stubsnsfisis
All ignored: Composer/Filesystem/Platform/Vcs repositories and the AuthHelper/Bitbucket/Git/Perforce/RemoteFilesystem/Svn utils mock IO/Config/HttpDownloader(curl)/ProcessExecutor or use reflection; Filesystem/ProcessExecutor/StreamContextFactory/ProxyManager need on-disk fixtures or proxy env. setUp/tearDown not ported. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-21test: port package archiver/loader/version/locker and PluginInstaller stubsnsfisis
All ignored: ArrayLoader/ValidatingArrayLoader/VersionSelector parse constraints via a look-around regex; ArchiveManager uses PharData (todo!()); ArchivableFilesFinder/VersionGuesser/Locker mock git/process/IO; the plugin API is not implemented (TODO(plugin)). Wires up the plugin test target. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-21test: add empty test filesnsfisis