Mercurial > hg
comparison tests/hghave.py @ 46177:0c320e6032f1
chg: format code by clang-format version 11.0.1-+rc1-1
test-check-clang-format.t started failing on my Debian sid environment, and
new style looks slightly better. So let's bump the required clang-format
version to 11.
author | Yuya Nishihara <yuya@tcha.org> |
---|---|
date | Sat, 19 Dec 2020 12:07:24 +0900 |
parents | ebcc52046096 |
children | 7149fb17ff72 |
comparison
equal
deleted
inserted
replaced
46176:300f6e23882a | 46177:0c320e6032f1 |
---|---|
592 | 592 |
593 | 593 |
594 @check("clang-format", "clang-format C code formatter") | 594 @check("clang-format", "clang-format C code formatter") |
595 def has_clang_format(): | 595 def has_clang_format(): |
596 m = matchoutput('clang-format --version', br'clang-format version (\d+)') | 596 m = matchoutput('clang-format --version', br'clang-format version (\d+)') |
597 # style changed somewhere between 4.x and 6.x | 597 # style changed somewhere between 10.x and 11.x |
598 return m and int(m.group(1)) >= 6 | 598 return m and int(m.group(1)) >= 11 |
599 | 599 |
600 | 600 |
601 @check("jshint", "JSHint static code analysis tool") | 601 @check("jshint", "JSHint static code analysis tool") |
602 def has_jshint(): | 602 def has_jshint(): |
603 return matchoutput("jshint --version 2>&1", br"jshint v") | 603 return matchoutput("jshint --version 2>&1", br"jshint v") |