crowdsec/pkg/hubtest
Laurence Jones b8e6bd8c9a
[Explain] s02 can cause panic if empty (#2486)
* Add parsers length check as it can panic is enrich is empty

* Lets get smarter and loop backwards to find last successful stage

* Shorten code

---------

Co-authored-by: Thibault "bui" Koechlin <thibault@crowdsec.net>
2023-09-29 12:03:56 +01:00
..
coverage.go enabled linters: gocritic, nilerr (#1853) 2022-11-07 10:36:50 +01:00
hubtest.go errors.Wrap -> fmt.Errorf (#2317) 2023-06-29 11:34:59 +02:00
hubtest_item.go fix the ci by adding the ability to enforce event ordering (#2347) 2023-07-20 11:41:30 +02:00
parser_assert.go [Explain] s02 can cause panic if empty (#2486) 2023-09-29 12:03:56 +01:00
scenario_assert.go errors.Wrap -> fmt.Errorf (#2317) 2023-06-29 11:34:59 +02:00
utils.go rename pkg/cstest -> pkg/hubtest (#1811) 2022-10-17 09:24:07 +02:00
utils_test.go rename pkg/cstest -> pkg/hubtest (#1811) 2022-10-17 09:24:07 +02:00