env NO_COLOR=1
exec pint --no-color lint --min-severity=info rules
! stdout .
cmp stderr stderr.txt

-- stderr.txt --
level=INFO msg="Loading configuration file" path=.pint.hcl
level=INFO msg="Finding all rules to check" paths=["rules"]
rules/0001.yaml:2 Warning: `errors[1h1s]` selector is trying to query Prometheus for 1h1s worth of metrics, but 1h is the maximum allowed range query. (promql/range_query)
 2 |   expr: sum(rate(errors[1h1s])) > 0.5

level=INFO msg="Problems found" Warning=1
-- rules/0001.yaml --
- alert: Error Rate
  expr: sum(rate(errors[1h1s])) > 0.5

- alert: Error Rate
  expr: sum(rate(errors[1h])) > 0.5

-- .pint.hcl --
parser {
  relaxed = [".*"]
}
rule {
  range_query {
    max      = "1h"
  }
}
