Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Have YAML matchers in addition to JSON matchers #2668

Open
sschuberth opened this issue Nov 24, 2021 · 6 comments
Open

Have YAML matchers in addition to JSON matchers #2668

sschuberth opened this issue Nov 24, 2021 · 6 comments
Labels
assertions 🔍 Related to the assertion mechanisms within the testing framework. enhancement ✨ Suggestions for adding new features or improving existing ones. good-first-issue 👶 Suitable for newcomers looking to contribute to the project. pinned 📌 Issues of high importance or that need to remain visible.

Comments

@sschuberth
Copy link
Member

Just like Json Matchers, we should have Yaml Matchers, too. While I'm aware that kotlinx.serialization has no built-in support for YAML, there is the multi-platform https://github.com/him188/yamlkt add-on for kotlinx.serialization which we could probably use.

@sschuberth sschuberth added the enhancement ✨ Suggestions for adding new features or improving existing ones. label Nov 24, 2021
@sksamuel sksamuel added assertions 🔍 Related to the assertion mechanisms within the testing framework. good-first-issue 👶 Suitable for newcomers looking to contribute to the project. labels Nov 27, 2021
@stale
Copy link

stale bot commented Jan 18, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale 🏚️ Issues that were lost to time and are no longer up-to-date label Jan 18, 2022
@sksamuel sksamuel added the pinned 📌 Issues of high importance or that need to remain visible. label Jan 19, 2022
@stale stale bot removed the stale 🏚️ Issues that were lost to time and are no longer up-to-date label Jan 19, 2022
@sksamuel sksamuel modified the milestones: 5.1.1, 5.2 Jan 22, 2022
@sksamuel sksamuel modified the milestones: 5.2, 5.3 Mar 12, 2022
@pientaa
Copy link
Contributor

pientaa commented Mar 21, 2022

@sschuberth are you sure that using the library you mentioned is the good idea? It looks like not being supported recently.

The alternative could be https://github.com/charleskorn/kaml, but it works only on JVM. However there is an open issue charleskorn/kaml#232 to add other targets, too. So, wouldn't it be better to wait until that issue is done?

@sksamuel
Copy link
Member

Let's ask @charleskorn since he uses Kotest :)

@charleskorn
Copy link
Contributor

If anyone is interested in contributing support for other targets to kaml, I'd be keen to help out, but it's not high on my list of priorities at the moment unfortunately.

@sschuberth
Copy link
Member Author

@sschuberth are you sure that using the library you mentioned is the good idea?

Of course I cannot tell for sure. But personally I strongly prefer multiplatform Kotlin code over something that just wraps existing Java libraries.

It looks like not being supported recently.

I'm not sure what you mean by "supported". It's open source, so if you feel that something needs to be improved, you should contribute. We cannot expect @Him188 to do all the work for us.

Also, https://github.com/him188/yamlkt does not look unmaintained to me just because the last release is from August 2021; there were still commits in the last month.

@Him188
Copy link

Him188 commented Mar 22, 2022

Yes, yamlkt is indeed in support. YAML is complex to implement from the beginning, and requires a lot of work. I will continue working on it, and I appreciate anyone who wants to contribute to yamlkt.

A remind: yamlkt is still in pre-release stage. API is subject to change in the future, and yamlkt currently doesn't support all the features, like anchors. Unfortunately, I cannot guarante a specific timeline for them.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
assertions 🔍 Related to the assertion mechanisms within the testing framework. enhancement ✨ Suggestions for adding new features or improving existing ones. good-first-issue 👶 Suitable for newcomers looking to contribute to the project. pinned 📌 Issues of high importance or that need to remain visible.
Projects
None yet
Development

No branches or pull requests

6 participants