This library is here to help you with all your data validation needs. It's ideally suited to writing tests against JSON-like structures, but can do much much more. We use it in elastic/beats for our own tests.
- GoDoc for this library.
- Runnable Examples.
If using go modules edit go.mod
, adding the following to your require list, replacing VERSION, with the latest version from our releases page.
require (
github.com/elastic/go-lookslike VERSION
)
If using govendor run:
govendor fetch github.com/elastic/go-lookslike
lookslike was created to improve the testing of various structures in elastic/beats. Searching the tests for lookslike.MustCompile
will show real world usage.
We currently define only the isdefs we've actually used in the field. If you'd like to add your own, please open a PR (with tests!).