Skip to content

use toml-test to generate tests#911

Merged
pelletier merged 2 commits intopelletier:v2from
mpldr:toml-test
Oct 26, 2023
Merged

use toml-test to generate tests#911
pelletier merged 2 commits intopelletier:v2from
mpldr:toml-test

Conversation

@mpldr
Copy link
Copy Markdown
Contributor

@mpldr mpldr commented Oct 25, 2023

This patch enables using toml-test to generate the testfiles. The tests currently generated fail to compile, but as far as I can tell at 12:40 am this seems not to be caused by me. I at least hope it's something trivial to fix.

@pelletier
Copy link
Copy Markdown
Owner

Thank you for taking a stab at this!

The tests currently generated fail to compile

Tests don't compile because some of them are generated multiple times in toml_testgen_test.go. For example:

$ ag TestTOMLTest_Invalid_NoClose1
toml_testgen_test.go
38:func TestTOMLTest_Invalid_NoClose1(t *testing.T) {
733:func TestTOMLTest_Invalid_NoClose1(t *testing.T) {
1578:func TestTOMLTest_Invalid_NoClose1(t *testing.T) {
1708:func TestTOMLTest_Invalid_NoClose1(t *testing.T) {

I haven't looked into it but seems like the new way to generate test name isn't unique enough?

@mpldr
Copy link
Copy Markdown
Contributor Author

mpldr commented Oct 26, 2023 via email

@pelletier pelletier added the build Issues regarding go-toml's CI system. label Oct 26, 2023
mpldr added 2 commits October 26, 2023 19:49
Add dependency on current HEAD of toml-test, since -copy is not yet
released and use it instead of the zip-download to fetch test files.

Fixes: #909
@mpldr
Copy link
Copy Markdown
Contributor Author

mpldr commented Oct 26, 2023

Now all issues should be resolved.

@mpldr mpldr mentioned this pull request Oct 26, 2023
@pelletier
Copy link
Copy Markdown
Owner

Looking good! Thank you for taking care of this!

@pelletier pelletier merged commit 358c8d2 into pelletier:v2 Oct 26, 2023
jooola referenced this pull request in hetznercloud/cli Dec 12, 2023
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
|
[github.com/pelletier/go-toml/v2](https://togithub.com/pelletier/go-toml)
| require | patch | `v2.1.0` -> `v2.1.1` |

---

### Release Notes

<details>
<summary>pelletier/go-toml (github.com/pelletier/go-toml/v2)</summary>

###
[`v2.1.1`](https://togithub.com/pelletier/go-toml/releases/tag/v2.1.1)

[Compare
Source](https://togithub.com/pelletier/go-toml/compare/v2.1.0...v2.1.1)

<!-- Release notes generated using configuration in .github/release.yml
at v2.1.1 -->

##### What's Changed

##### Fixed bugs

- Fix unmarshaling of nested non-exported struct by
[@&#8203;pelletier](https://togithub.com/pelletier) in
[https://github.com/pelletier/go-toml/pull/917](https://togithub.com/pelletier/go-toml/pull/917)

##### New Contributors

- [@&#8203;arp242](https://togithub.com/arp242) made their first
contribution in
[https://github.com/pelletier/go-toml/pull/907](https://togithub.com/pelletier/go-toml/pull/907)
- [@&#8203;mpldr](https://togithub.com/mpldr) made their first
contribution in
[https://github.com/pelletier/go-toml/pull/911](https://togithub.com/pelletier/go-toml/pull/911)

**Full Changelog**:
pelletier/go-toml@v2.1.0...v2.1.1

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined),
Automerge - At any time (no schedule defined).

🚦 **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 [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View
repository job log
[here](https://developer.mend.io/github/hetznercloud/cli).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy44Ny4yIiwidXBkYXRlZEluVmVyIjoiMzcuODcuMiIsInRhcmdldEJyYW5jaCI6Im1haW4ifQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

build Issues regarding go-toml's CI system.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants