diff --git a/.circleci/config.yml b/.circleci/config.yml new file mode 100644 index 00000000..c76072a8 --- /dev/null +++ b/.circleci/config.yml @@ -0,0 +1,12 @@ +jobs: + build: + docker: + - image: cimg/ruby:3.3.5 + environment: + RAILS_ENV: test + steps: + - checkout + - run: | + bundle install + - run: | + bundle exec rake test diff --git a/.travis.yml b/.travis.yml index a8f407e5..6c607d27 100644 --- a/.travis.yml +++ b/.travis.yml @@ -3,6 +3,7 @@ env: - "JRUBY_OPTS=-Xcext.enabled=true" - "CC_TEST_REPORTER_ID=faa393209ff0a104cf37511a9a03510bcee37951971b1ca4ffc2af217851d47e" language: ruby +os: linux rvm: - 1.8.7 - ree @@ -15,11 +16,15 @@ rvm: - 2.5 - 2.6 - 2.7 + - 3.0 + - 3.1 + - 3.2 - ruby-head - jruby -matrix: +jobs: allow_failures: - rvm: 1.8.7 + - rvm: ree - rvm: ruby-head - rvm: jruby branches: @@ -33,4 +38,3 @@ before_script: script: "rake test" # test:scanners" after_script: - ./cc-test-reporter after-build --exit-code $TRAVIS_TEST_RESULT -sudo: false diff --git a/Gemfile b/Gemfile index 1851939d..49ac338d 100644 --- a/Gemfile +++ b/Gemfile @@ -13,7 +13,7 @@ group :development do gem 'RedCloth', RUBY_PLATFORM == 'java' ? '= 4.2.9' : '>= 4.0.3' gem 'rspec', '~> 3.9.0' gem 'shoulda-context', RUBY_VERSION < '1.9' ? '= 1.2.1' : '>= 1.2.1' - gem 'simplecov', '~> 0.17.1' + gem 'simplecov', RUBY_VERSION < '2.7' ? '~> 0.17.1' : '>= 0.18.5' gem 'term-ansicolor', RUBY_VERSION < '2.0' ? '~> 1.3.2' : '>= 1.3.2' gem 'test-unit', RUBY_VERSION < '1.9' ? '~> 2.0' : '>= 3.0' gem 'tins', RUBY_VERSION < '2.0' ? '~> 1.6.0' : '>= 1.6.0' diff --git a/MIT-LICENSE b/MIT-LICENSE index d8d009d1..9431e246 100644 --- a/MIT-LICENSE +++ b/MIT-LICENSE @@ -1,4 +1,4 @@ -Copyright (C) 2005-2012 Kornelius Kalnbach (@murphy_karasu) +Copyright (C) 2005 Kornelius Kalnbach (@murphy_karasu) http://coderay.rubychan.de/ @@ -19,4 +19,4 @@ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. \ No newline at end of file +WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/README.markdown b/README.markdown index 410d1bff..a768ef10 100644 --- a/README.markdown +++ b/README.markdown @@ -1,7 +1,6 @@ # CodeRay -[![Build Status](https://travis-ci.org/rubychan/coderay.svg?branch=master)](https://travis-ci.org/rubychan/coderay) -[![Gem Version](https://badge.fury.io/rb/coderay.svg)](https://badge.fury.io/rb/coderay) [![Maintainability](https://api.codeclimate.com/v1/badges/e015bbd5eab45d948b6b/maintainability)](https://codeclimate.com/github/rubychan/coderay/maintainability) +[![CircleCI](https://dl.circleci.com/status-badge/img/gh/rubychan/coderay/tree/master.svg?style=svg&circle-token=CCIPRJ_BbFff6nMhNtPdrCBNMDxNq_be00bbb00849a29d8d8d2e28e7b84cbf76a9ee5c)](https://dl.circleci.com/status-badge/redirect/gh/rubychan/coderay/tree/master) [![Gem Version](https://badge.fury.io/rb/coderay.svg)](https://badge.fury.io/rb/coderay) [![Maintainability](https://api.codeclimate.com/v1/badges/e015bbd5eab45d948b6b/maintainability)](https://codeclimate.com/github/rubychan/coderay/maintainability) ## About diff --git a/coderay.gemspec b/coderay.gemspec index 14500ad9..9aba34eb 100644 --- a/coderay.gemspec +++ b/coderay.gemspec @@ -28,6 +28,6 @@ Gem::Specification.new do |s| s.executables = `git ls-files -- bin/*`.split("\n").map { |f| File.basename(f) } s.require_paths = ['lib'] - s.rdoc_options = '-SNw2', "-m#{readme_file}", '-t CodeRay Documentation' + s.rdoc_options = '-Nw2', "-m#{readme_file}", '-t CodeRay Documentation' s.extra_rdoc_files = readme_file end diff --git a/test/unit/debug.rb b/test/unit/debug.rb index 88baf563..b694f21e 100644 --- a/test/unit/debug.rb +++ b/test/unit/debug.rb @@ -24,7 +24,8 @@ def test_creation [" \n", :space], ["[]", :method], [:end_line, :head], - ].flatten + ] + TEST_INPUT.flatten! TEST_OUTPUT = <<-'DEBUG'.chomp integer(10)operator((\\\))stringhead[ diff --git a/test/unit/statistic.rb b/test/unit/statistic.rb index 1326dca6..776774d4 100644 --- a/test/unit/statistic.rb +++ b/test/unit/statistic.rb @@ -24,7 +24,8 @@ def test_creation [" \n", :space], ["[]", :method], [:end_line, :test], - ].flatten + ] + TEST_INPUT.flatten! TEST_OUTPUT = <<-'DEBUG' Code Statistics @@ -56,4 +57,4 @@ def test_filtering_text_tokens assert_equal TEST_OUTPUT, TEST_INPUT.statistic end -end \ No newline at end of file +end