Commit Graph

4 Commits

Author SHA1 Message Date
Trevor Brown
f74efbf1bf feat(golang-rewrite): offline Go tests
Some of the Go tests actually cloned remote repos, which meant slow tests, and tests failures if I was working offline. These changes allow all Go tests to run offline. The test code now clones local Git repos instead of remotes ones.

* Add otiai10/copy as a dependency
* Create repotest package for test code that needs to work with Git repos
* Add back missing test script for execute package
* Update git, pluginindex, and plugins package tests so they work offline
2024-12-18 11:32:01 -05:00
Trevor Brown
8394e858fe feat(golang-rewrite): use plugin index
* Create `pluginindex.Build` function
* Use `pluginindex` when no plugin URL provided for plugin add command
* Get more `plugin_add_command` BATS tests passing against Golang version
* Only use `pluginindex` when it is not disabled
* Update error message so it matches legacy format
* Add staticcheck.conf
2024-12-18 11:32:01 -05:00
Trevor Brown
cb49b64a5a feat(golang-rewrite): move all Git code to git package
* Move plugins/git package to /git.
* Update repoer interface in pluginindex package to match interface in git package
* Use git package's Repo struct in pluginindex package
2024-12-18 11:32:01 -05:00
Trevor Brown
202cdae831 feat(golang-rewrite): create pluginindex package
* Switch to non-verbose test output in Makefile
* Create pluginindex package with PluginIndex struct with methods for updating index and retrieving plugin URLs
* Create IndexRepo interface to allow for easy testing out cloning real Git repository.
2024-12-18 11:32:01 -05:00