From 53fac0b72bad6d1b2494e9193cf56d201c74928d Mon Sep 17 00:00:00 2001 From: Ridhwanul Haque Date: Mon, 16 Jan 2017 09:53:33 +0600 Subject: [PATCH 1/2] Install Ruby gems in AppVeyor Added commands to install ruby gems in appveyor so that it can perform tests for the bears that use ruby gems. Closes https://github.com/coala/coala-bears/issues/1305 --- .ci/appveyor.yml | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/.ci/appveyor.yml b/.ci/appveyor.yml index 5963fabb81..26b8c68d1b 100644 --- a/.ci/appveyor.yml +++ b/.ci/appveyor.yml @@ -10,10 +10,12 @@ environment: - PYTHON: "C:\\Python34" PYTHON_VERSION: "3.4.4" PYTHON_ARCH: "32" + ruby_version: "22" - PYTHON: "C:\\Python34-x64" PYTHON_VERSION: "3.4.4" PYTHON_ARCH: "64" + ruby_version: "22-x64" cache: - "C:\\pip_cache" @@ -47,6 +49,12 @@ install: - "npm config set loglevel warn" - "npm install" + # Commands for Ruby + - sed -i '/ruby \'2\.2\.2\'/d' Gemfile + - "sed -i '/sqlint/d' Gemfile" + - "SET PATH=C:\\Ruby%ruby_version%\\bin;%PATH%" + - "bundle install" + build: false # Not a C# project, build stuff at the test step instead. test_script: @@ -62,7 +70,8 @@ test_script: "%CMD_IN_ENV% python -m pytest --cov -k "not ClangASTPrintBear and not ClangCloneDetectionBear and not ClangComplexityBear and not ClangCountVectorCreator and - not ClangCountingConditions" + not ClangCountingConditions and not RuboCopBearTest and + not CSVLintBearTest" - "%CMD_IN_ENV% python setup.py install" - "%CMD_IN_ENV% python -m pip install \ git+https://github.com/coala/coala" From f6119ad72929c174ccac55ce4a9879ee577ee26c Mon Sep 17 00:00:00 2001 From: John Vandenberg Date: Fri, 7 Dec 2018 22:05:15 +0700 Subject: [PATCH 2/2] .ci/appveyor.yml: Enable 100% coverage --- .ci/appveyor.yml | 1 - bears/configfiles/PuppetLintBear.py | 2 +- bears/haml/HAMLLintBear.py | 2 +- bears/ruby/RubySecurityBear.py | 2 +- bears/ruby/RubySmellBear.py | 2 +- bears/scss/SCSSLintBear.py | 2 +- bears/yaml/TravisLintBear.py | 2 +- 7 files changed, 6 insertions(+), 7 deletions(-) diff --git a/.ci/appveyor.yml b/.ci/appveyor.yml index 26b8c68d1b..51d9ba1556 100644 --- a/.ci/appveyor.yml +++ b/.ci/appveyor.yml @@ -62,7 +62,6 @@ test_script: # which defaults to CRLF on Windows, and Appveyor CI ignores .gitattributes # http://help.appveyor.com/discussions/problems/5687-gitattributes-changes-dont-have-any-effect - unix2dos tests/java/test_files/CheckstyleGood.java - - sed -i '/fail_under/d' setup.cfg # Clang DLLs x64 were nowadays installed, but the x64 version hangs, so we # exclude according tests. See https://github.com/appveyor/ci/issues/495 and # https://github.com/appveyor/ci/issues/688 diff --git a/bears/configfiles/PuppetLintBear.py b/bears/configfiles/PuppetLintBear.py index 67b5fce4d1..f7b8130a0b 100644 --- a/bears/configfiles/PuppetLintBear.py +++ b/bears/configfiles/PuppetLintBear.py @@ -6,7 +6,7 @@ output_format='regex', output_regex=r'(?P\d+):(?P\d+):' r'(?Pwarning|error):(?P.+)') -class PuppetLintBear: # pragma nt: no cover +class PuppetLintBear: ''' Check and correct puppet configuration files using ``puppet-lint``. diff --git a/bears/haml/HAMLLintBear.py b/bears/haml/HAMLLintBear.py index 66e5b40d4d..015f1623e3 100644 --- a/bears/haml/HAMLLintBear.py +++ b/bears/haml/HAMLLintBear.py @@ -10,7 +10,7 @@ output_format='regex', output_regex=r'(?P\d+) \[(?PW|E)\] ' r'(?P.*)') -class HAMLLintBear: # pragma nt: no cover +class HAMLLintBear: """ Uses ``haml-lint`` to perform HAML-specific style and lint checks to ensure clean and readable HAML code. diff --git a/bears/ruby/RubySecurityBear.py b/bears/ruby/RubySecurityBear.py index 9808d7e4ae..48cacde688 100644 --- a/bears/ruby/RubySecurityBear.py +++ b/bears/ruby/RubySecurityBear.py @@ -10,7 +10,7 @@ @linter(executable='brakeman', global_bear=True) -class RubySecurityBear: # pragma nt: no cover +class RubySecurityBear: """ Checks the Security issues of Ruby Applications. diff --git a/bears/ruby/RubySmellBear.py b/bears/ruby/RubySmellBear.py index 976b0ecea0..e92bcbbbcc 100644 --- a/bears/ruby/RubySmellBear.py +++ b/bears/ruby/RubySmellBear.py @@ -9,7 +9,7 @@ @linter(executable='reek', use_stdin=True) -class RubySmellBear: # pragma nt: no cover +class RubySmellBear: """ Detect code smells in Ruby source code. diff --git a/bears/scss/SCSSLintBear.py b/bears/scss/SCSSLintBear.py index 68a275cbc5..976b15ef24 100644 --- a/bears/scss/SCSSLintBear.py +++ b/bears/scss/SCSSLintBear.py @@ -10,7 +10,7 @@ output_regex=r'.+:(?P\d+):(?P\d+)\s+' r'\[(?P.)\]\s+' r'(?P.*)') -class SCSSLintBear: # pragma nt: no cover +class SCSSLintBear: """ Check SCSS code to keep it clean and readable. diff --git a/bears/yaml/TravisLintBear.py b/bears/yaml/TravisLintBear.py index 5306619c3c..fbb8e97b40 100644 --- a/bears/yaml/TravisLintBear.py +++ b/bears/yaml/TravisLintBear.py @@ -8,7 +8,7 @@ @linter(executable='travis', output_format='regex', output_regex=r'\[x\]\s+(?P.+)') -class TravisLintBear: # pragma nt: no cover +class TravisLintBear: """ A validator for your ``.travis.yml`` that attempts to reduce common build errors such as: