Closed habnabit closed 5 years ago
Thanks @habnabit! This is some great extra coverage for something that is easy to get wrong for sure.
We also have some other test cases that are intended to be used to test conformance for any possible future implementations of HCL (in other languages, perhaps). Although that test suite is far from complete right now, we do specifically have a heredoc test in there (under expressions
) specifically because that behavior has been historically tricky. Would you mind adding some similar tests to that heredoc test case in specsuite
so that future implementations can be verified too?
As mentioned in the readme, we have some code in the Go package tests to run those specsuite tests as part of a normal go test
on package ./hcl/spectests
, so you shouldn't need to do anything unusual to run them for testing.
If you don't have any more time to work on this then that's totally fine; I'm happy to make those updates myself when I get a chance, if not.
Thanks again!
I'm pretty sure I did change what you're talking about under specsuite
already? I might be missing something, but I think I did update both the golang tests and the specsuite. I based the changes I made off of what was changed in e8dbb16dbc7f9774afd808c19a0fd40d2347191f.
Hi @habnabit! Sorry, on a second look I see that you did; I guess something prevented the full "files changed" page from loading on my first read, and so I only saw the expression_test.go
changes. :thinking:
In that case, great! I will merge it now. Thanks again.