Bug 1874684 - Part 6: Limit day length calculations to safe integers. r=mgaudet
[gecko.git] / tools / lint / test / test_yaml.py
blob63b678d152b62fafb73f3cade479fef0b160cbef
1 import mozunit
3 LINTER = "yaml"
6 def test_basic(lint, paths):
7 results = lint(paths())
9 assert len(results) == 3
11 assert "line too long (122 > 80 characters)" in results[0].message
12 assert results[0].level == "error"
13 assert "bad.yml" in results[0].relpath
14 assert results[0].lineno == 3
16 assert "wrong indentation: expected 4 but found 8" in results[1].message
17 assert results[1].level == "error"
18 assert "bad.yml" in results[1].relpath
19 assert results[0].lineno == 3
21 assert "could not find expected" in results[2].message
22 assert results[2].level == "error"
23 assert "bad.yml" in results[2].relpath
24 assert results[2].lineno == 9
27 if __name__ == "__main__":
28 mozunit.main()