1
0
Fork 0
mirror of https://code.forgejo.org/forgejo/runner.git synced 2025-09-15 18:57:01 +00:00
Forgejo runner - alpha release, should not be considered secure enough to deploy in production
Find a file
Renovate Bot 0e780482eb
Update module github.com/stretchr/testify to v1.11.1 (#915)
This PR contains the following updates:

| Package | Change | Age | Confidence |
|---|---|---|---|
| [github.com/stretchr/testify](https://github.com/stretchr/testify) | `v1.10.0` -> `v1.11.1` | [![age](https://developer.mend.io/api/mc/badges/age/go/github.com%2fstretchr%2ftestify/v1.11.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/go/github.com%2fstretchr%2ftestify/v1.10.0/v1.11.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) |

---

### Release Notes

<details>
<summary>stretchr/testify (github.com/stretchr/testify)</summary>

### [`v1.11.1`](https://github.com/stretchr/testify/releases/tag/v1.11.1)

[Compare Source](https://github.com/stretchr/testify/compare/v1.11.0...v1.11.1)

This release fixes [#&#8203;1785](https://github.com/stretchr/testify/issues/1785) introduced in v1.11.0 where expected argument values implementing the stringer interface (`String() string`) with a method which mutates their value, when passed to mock.Mock.On (`m.On("Method", <expected>).Return()`) or actual argument values passed to mock.Mock.Called may no longer match one another where they previously did match. The behaviour prior to v1.11.0 where the stringer is always called is restored. Future testify releases may not call the stringer method at all in this case.

#### What's Changed

- Backport [#&#8203;1786](https://github.com/stretchr/testify/issues/1786) to release/1.11: mock: revert to pre-v1.11.0 argument matching behavior for mutating stringers by [@&#8203;brackendawson](https://github.com/brackendawson) in [#&#8203;1788](https://github.com/stretchr/testify/pull/1788)

**Full Changelog**: <https://github.com/stretchr/testify/compare/v1.11.0...v1.11.1>

### [`v1.11.0`](https://github.com/stretchr/testify/releases/tag/v1.11.0)

[Compare Source](https://github.com/stretchr/testify/compare/v1.10.0...v1.11.0)

#### What's Changed

##### Functional Changes

v1.11.0 Includes a number of performance improvements.

- Call stack perf change for CallerInfo by [@&#8203;mikeauclair](https://github.com/mikeauclair) in [#&#8203;1614](https://github.com/stretchr/testify/pull/1614)
- Lazily render mock diff output on successful match by [@&#8203;mikeauclair](https://github.com/mikeauclair) in [#&#8203;1615](https://github.com/stretchr/testify/pull/1615)
- assert: check early in Eventually, EventuallyWithT, and Never by [@&#8203;cszczepaniak](https://github.com/cszczepaniak) in [#&#8203;1427](https://github.com/stretchr/testify/pull/1427)
- assert: add IsNotType by [@&#8203;bartventer](https://github.com/bartventer) in [#&#8203;1730](https://github.com/stretchr/testify/pull/1730)
- assert.JSONEq: shortcut if same strings by [@&#8203;dolmen](https://github.com/dolmen) in [#&#8203;1754](https://github.com/stretchr/testify/pull/1754)
- assert.YAMLEq: shortcut if same strings by [@&#8203;dolmen](https://github.com/dolmen) in [#&#8203;1755](https://github.com/stretchr/testify/pull/1755)
- assert: faster and simpler isEmpty using reflect.Value.IsZero by [@&#8203;dolmen](https://github.com/dolmen) in [#&#8203;1761](https://github.com/stretchr/testify/pull/1761)
- suite: faster methods filtering (internal refactor) by [@&#8203;dolmen](https://github.com/dolmen) in [#&#8203;1758](https://github.com/stretchr/testify/pull/1758)

##### Fixes

- assert.ErrorAs: log target type by [@&#8203;craig65535](https://github.com/craig65535) in [#&#8203;1345](https://github.com/stretchr/testify/pull/1345)
- Fix failure message formatting for Positive and Negative asserts in [#&#8203;1062](https://github.com/stretchr/testify/pull/1062)
- Improve ErrorIs message when error is nil but an error was expected by [@&#8203;tsioftas](https://github.com/tsioftas) in [#&#8203;1681](https://github.com/stretchr/testify/pull/1681)
- fix Subset/NotSubset when calling with mixed input types by [@&#8203;siliconbrain](https://github.com/siliconbrain) in [#&#8203;1729](https://github.com/stretchr/testify/pull/1729)
- Improve ErrorAs failure message when error is nil by [@&#8203;ccoVeille](https://github.com/ccoVeille) in [#&#8203;1734](https://github.com/stretchr/testify/pull/1734)
- mock.AssertNumberOfCalls: improve error msg by [@&#8203;3scalation](https://github.com/3scalation) in [#&#8203;1743](https://github.com/stretchr/testify/pull/1743)

##### Documentation, Build & CI

- docs: Fix typo in README by [@&#8203;alexandear](https://github.com/alexandear) in [#&#8203;1688](https://github.com/stretchr/testify/pull/1688)
- Replace deprecated io/ioutil with io and os by [@&#8203;alexandear](https://github.com/alexandear) in [#&#8203;1684](https://github.com/stretchr/testify/pull/1684)
- Document consequences of calling t.FailNow() by [@&#8203;greg0ire](https://github.com/greg0ire) in [#&#8203;1710](https://github.com/stretchr/testify/pull/1710)
- chore: update docs for Unset [#&#8203;1621](https://github.com/stretchr/testify/issues/1621) by [@&#8203;techfg](https://github.com/techfg) in [#&#8203;1709](https://github.com/stretchr/testify/pull/1709)
- README: apply gofmt to examples by [@&#8203;alexandear](https://github.com/alexandear) in [#&#8203;1687](https://github.com/stretchr/testify/pull/1687)
- refactor: use %q and %T to simplify fmt.Sprintf by [@&#8203;alexandear](https://github.com/alexandear) in [#&#8203;1674](https://github.com/stretchr/testify/pull/1674)
- Propose Christophe Colombier (ccoVeille) as approver by [@&#8203;brackendawson](https://github.com/brackendawson) in [#&#8203;1716](https://github.com/stretchr/testify/pull/1716)
- Update documentation for the Error function in assert or require package by [@&#8203;architagr](https://github.com/architagr) in [#&#8203;1675](https://github.com/stretchr/testify/pull/1675)
- assert: remove deprecated build constraints by [@&#8203;alexandear](https://github.com/alexandear) in [#&#8203;1671](https://github.com/stretchr/testify/pull/1671)
- assert: apply gofumpt to internal test suite by [@&#8203;ccoVeille](https://github.com/ccoVeille) in [#&#8203;1739](https://github.com/stretchr/testify/pull/1739)
- CI: fix shebang in .ci.\*.sh scripts by [@&#8203;dolmen](https://github.com/dolmen) in [#&#8203;1746](https://github.com/stretchr/testify/pull/1746)
- assert,require: enable parallel testing on (almost) all top tests by [@&#8203;dolmen](https://github.com/dolmen) in [#&#8203;1747](https://github.com/stretchr/testify/pull/1747)
- suite.Passed: add one more status test report by [@&#8203;Ararsa-Derese](https://github.com/Ararsa-Derese) in [#&#8203;1706](https://github.com/stretchr/testify/pull/1706)
- Add Helper() method in internal mocks and assert.CollectT by [@&#8203;dolmen](https://github.com/dolmen) in [#&#8203;1423](https://github.com/stretchr/testify/pull/1423)
- assert.Same/NotSame: improve usage of Sprintf by [@&#8203;ccoVeille](https://github.com/ccoVeille) in [#&#8203;1742](https://github.com/stretchr/testify/pull/1742)
- mock: enable parallel testing on internal testsuite by [@&#8203;dolmen](https://github.com/dolmen) in [#&#8203;1756](https://github.com/stretchr/testify/pull/1756)
- suite: cleanup use of 'testing' internals at runtime by [@&#8203;dolmen](https://github.com/dolmen) in [#&#8203;1751](https://github.com/stretchr/testify/pull/1751)
- assert: check test failure message for Empty and NotEmpty  by [@&#8203;ccoVeille](https://github.com/ccoVeille) in [#&#8203;1745](https://github.com/stretchr/testify/pull/1745)
- deps: fix dependency cycle with objx (again) by [@&#8203;dolmen](https://github.com/dolmen) in [#&#8203;1567](https://github.com/stretchr/testify/pull/1567)
- assert.Empty: comprehensive doc of "Empty"-ness rules by [@&#8203;dolmen](https://github.com/dolmen) in [#&#8203;1753](https://github.com/stretchr/testify/pull/1753)
- doc: improve godoc of top level 'testify' package by [@&#8203;dolmen](https://github.com/dolmen) in [#&#8203;1760](https://github.com/stretchr/testify/pull/1760)
- assert.ErrorAs: simplify retrieving the type name by [@&#8203;ccoVeille](https://github.com/ccoVeille) in [#&#8203;1740](https://github.com/stretchr/testify/pull/1740)
- assert.EqualValues: improve test coverage to 100% by [@&#8203;dolmen](https://github.com/dolmen) in [#&#8203;1763](https://github.com/stretchr/testify/pull/1763)
- suite.Run: simplify running of Setup/TeardownSuite by [@&#8203;renzoarreaza](https://github.com/renzoarreaza) in [#&#8203;1769](https://github.com/stretchr/testify/pull/1769)
- assert.CallerInfo: micro optimization by using LastIndexByte by [@&#8203;dolmen](https://github.com/dolmen) in [#&#8203;1767](https://github.com/stretchr/testify/pull/1767)
- assert.CallerInfo: micro cleanup by [@&#8203;dolmen](https://github.com/dolmen) in [#&#8203;1768](https://github.com/stretchr/testify/pull/1768)
- assert: refactor Test*FileExists and Test*DirExists tests to enable parallel testing by [@&#8203;dolmen](https://github.com/dolmen) in [#&#8203;1766](https://github.com/stretchr/testify/pull/1766)
- suite.Run: refactor handling of stats for improved readability by [@&#8203;dolmen](https://github.com/dolmen) in [#&#8203;1764](https://github.com/stretchr/testify/pull/1764)
- tests: improve captureTestingT helper by [@&#8203;ccoVeille](https://github.com/ccoVeille) in [#&#8203;1741](https://github.com/stretchr/testify/pull/1741)
- build(deps): bump actions/checkout from 4 to 5 by [@&#8203;dependabot](https://github.com/dependabot)\[bot] in [#&#8203;1778](https://github.com/stretchr/testify/pull/1778)

#### New Contributors

- [@&#8203;greg0ire](https://github.com/greg0ire) made their first contribution in [#&#8203;1710](https://github.com/stretchr/testify/pull/1710)
- [@&#8203;techfg](https://github.com/techfg) made their first contribution in [#&#8203;1709](https://github.com/stretchr/testify/pull/1709)
- [@&#8203;mikeauclair](https://github.com/mikeauclair) made their first contribution in [#&#8203;1614](https://github.com/stretchr/testify/pull/1614)
- [@&#8203;cszczepaniak](https://github.com/cszczepaniak) made their first contribution in [#&#8203;1427](https://github.com/stretchr/testify/pull/1427)
- [@&#8203;architagr](https://github.com/architagr) made their first contribution in [#&#8203;1675](https://github.com/stretchr/testify/pull/1675)
- [@&#8203;tsioftas](https://github.com/tsioftas) made their first contribution in [#&#8203;1681](https://github.com/stretchr/testify/pull/1681)
- [@&#8203;siliconbrain](https://github.com/siliconbrain) made their first contribution in [#&#8203;1729](https://github.com/stretchr/testify/pull/1729)
- [@&#8203;bartventer](https://github.com/bartventer) made their first contribution in [#&#8203;1730](https://github.com/stretchr/testify/pull/1730)
- [@&#8203;Ararsa-Derese](https://github.com/Ararsa-Derese) made their first contribution in [#&#8203;1706](https://github.com/stretchr/testify/pull/1706)
- [@&#8203;renzoarreaza](https://github.com/renzoarreaza) made their first contribution in [#&#8203;1769](https://github.com/stretchr/testify/pull/1769)
- [@&#8203;3scalation](https://github.com/3scalation) made their first contribution in [#&#8203;1743](https://github.com/stretchr/testify/pull/1743)

**Full Changelog**: <https://github.com/stretchr/testify/compare/v1.10.0...v1.11.0>

</details>

---

### Configuration

📅 **Schedule**: Branch creation - Between 12:00 AM and 03:59 AM ( * 0-3 * * * ) (UTC), Automerge - Between 12:00 AM and 03:59 AM ( * 0-3 * * * ) (UTC).

🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update again.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box

---

This PR has been generated by [Renovate Bot](https://github.com/renovatebot/renovate).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0MS44Mi4xMCIsInVwZGF0ZWRJblZlciI6IjQxLjgyLjEwIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJLaW5kL0Nob3JlIl19-->

<!--start release-notes-assistant-->
<!--URL:https://code.forgejo.org/forgejo/runner-->
- other
  - [PR](https://code.forgejo.org/forgejo/runner/pulls/915): <!--number 915 --><!--line 0 --><!--description VXBkYXRlIG1vZHVsZSBnaXRodWIuY29tL3N0cmV0Y2hyL3Rlc3RpZnkgdG8gdjEuMTEuMQ==-->Update module github.com/stretchr/testify to v1.11.1<!--description-->
<!--end release-notes-assistant-->

Reviewed-on: https://code.forgejo.org/forgejo/runner/pulls/915
Reviewed-by: earl-warren <earl-warren@noreply.code.forgejo.org>
Co-authored-by: Renovate Bot <bot@kriese.eu>
Co-committed-by: Renovate Bot <bot@kriese.eu>
2025-08-28 09:31:53 +00:00
.forgejo chore: do not force GOPROXY (#899) 2025-08-21 11:53:48 +00:00
.github/workflows chore: restore GitHub windows build workflow (#815) 2025-08-07 08:56:39 +00:00
act chore: remove TestRunContext_GetGitHubContext (#900) 2025-08-21 11:54:04 +00:00
contrib Restore contrib/forgejo-runner.service (#772) 2025-07-30 22:16:05 +00:00
examples Update dependency forgejo/runner to v9.1.1 (#898) 2025-08-21 07:16:34 +00:00
internal test: remove internal timeout in TestRunnerCacheConfiguration (#906) 2025-08-22 05:09:36 +00:00
release-notes feat: add the runner validate subcommand (#757) 2025-07-31 05:37:12 +00:00
testutils feat: add the runner validate subcommand (#757) 2025-07-31 05:37:12 +00:00
.dockerignore [FORGEJO] build forgejo-runner 2023-08-23 14:44:47 +02:00
.editorconfig Add .editorconfig and .gitattributes (#186) 2023-05-13 23:51:22 +08:00
.gitattributes Add .editorconfig and .gitattributes (#186) 2023-05-13 23:51:22 +08:00
.gitignore chore: remove unused code and comments including gitea 2025-07-03 18:58:11 +02:00
.golangci.yml chore: use t.Context for tests, activate usetesting for lint + add t.TempDir and t.Chdir (#844) 2025-08-11 13:21:42 +00:00
Dockerfile Update data.forgejo.org/oci/alpine Docker tag to v3.22 (#616) 2025-06-18 05:43:57 +00:00
go.mod Update module github.com/stretchr/testify to v1.11.1 (#915) 2025-08-28 09:31:53 +00:00
go.sum Update module github.com/stretchr/testify to v1.11.1 (#915) 2025-08-28 09:31:53 +00:00
LICENSE chore: update LICENSE year 2025-07-03 18:58:11 +02:00
main.go chore: to allow the runner to be imported, v9 needs to be in the go module (#777) 2025-07-31 10:35:11 +00:00
Makefile chore: fix .PHONY lint targets (#893) 2025-08-21 11:24:11 +00:00
README.md chore: rework the README (#903) 2025-08-21 19:48:28 +00:00
RELEASE-NOTES.md chore: release notes are now published together with the release (#775) 2025-07-31 08:02:20 +00:00
renovate.json chore: set the Kind/Chore label on dependencies upgrades (#842) 2025-08-11 08:30:33 +00:00

Forgejo Runner

A daemon that connects to a Forgejo instance and runs jobs for continuous integration. The installation and usage instructions are part of the Forgejo documentation.

Reporting security-related issues

Sensitive security-related issues should be reported to security@forgejo.org using encryption.

License

The Forgejo runner source code is distributed under the terms of the following licenses:

Architectures & OS

The Forgejo runner is supported and tested on amd64 and arm64 (binaries and containers) on Operating Systems based on the Linux kernel.

Work may be in progress for other architectures and you can browse the corresponding issues to figure out how they make progress. If you are interested in helping them move forward, open an issue. The most challenging part is to setup and maintain a native runner long term. Once it is supported by Forgejo, the runner is expected to be available 24/7 which can be challenging. Otherwise debugging any architecture specific problem won't be possible.

Hacking

The Forgejo runner is a dependency of the setup-forgejo action. See the full dependency graph for a global view.

Building

  • Install Go and make(1)
  • make build

Linting

  • make lint-check
  • make lint # will fix some lint errors

Testing

The workflow that runs in the CI uses similar commands.

Without a Forgejo instance

  • Install Docker
  • make test integration-test

With a Forgejo instance

  • Run a Forgejo instance locally (for instance at http://0.0.0.0:8080) and create as shared secret
export FORGEJO_RUNNER_SECRET='AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA'
export FORGEJO_URL=http://0.0.0.0:8080
forgejo forgejo-cli actions register --labels docker --name therunner --secret $FORGEJO_RUNNER_SECRET
  • make test integration-test # which will run addional tests because FORGEJO_URL is set

end-to-end

  • Follow the instructions from the end-to-end tests to run actions tests locally.
  • ./end-to-end.sh actions_teardown # stop the Forgejo and runner daemons running in the end-to-end environment
  • ( cd ~/clone-of-the-runner-repo ; make build ; cp forgejo-runner /tmp/forgejo-end-to-end/forgejo-runner ) # install the runner built from sources
  • ./end-to-end.sh actions_setup 13.0 # start Forgejo v13.0 and the runner daemon in the end-to-end environment
  • ./end-to-end.sh actions_verify_example echo # run the echo workflow
  • xdg-open http://127.0.0.1:3000/root/example-echo/actions/runs/1 # see the logs workflow
  • less /tmp/forgejo-end-to-end/forgejo-runner.log # analyze the runner logs
  • less /tmp/forgejo-end-to-end/forgejo-work-path/log/forgejo.log # analyze the Forgejo logs