Ejemplo n.º 1
0
 def test_runner_with_matches(self):
     # Check the integer returned by saltlint.cli.run(), when matches are
     # expected.
     args = ['tests/test-extension-failure']
     self.assertEqual(run(args), 2)
Ejemplo n.º 2
0
 def test_runner_without_matches(self):
     # Check the integer returned by saltlint.cli.run(), when no matches are
     # expected.
     args = ['tests/test-extension-success.sls']
     self.assertEqual(run(args), 0)
Ejemplo n.º 3
0
# -*- coding: utf-8 -*-
# Copyright (c) 2013-2014 Will Thames <*****@*****.**>
# Modified work Copyright (c) 2019 Roald Nefs

import sys
import errno

from saltlint.cli import run

if __name__ == "__main__":
    try:
        sys.exit(run())
    except IOError as exc:
        if exc.errno != errno.EPIPE:
            raise
    except RuntimeError as e:
        raise SystemExit(str(e))