diff --git a/.github/workflows/ruby.yml b/.github/workflows/ruby.yml new file mode 100644 index 0000000..cd767e3 --- /dev/null +++ b/.github/workflows/ruby.yml @@ -0,0 +1,32 @@ +name: Ruby + +on: + push: + branches: [ "master", "1.2.0" ] + pull_request: + branches: [ "master", "1.2.0" ] + +permissions: + contents: read + +jobs: + test: + + runs-on: ubuntu-latest + strategy: + matrix: + ruby-version: ['2.6', '2.7.8'] + + steps: + - uses: actions/checkout@v3 + - name: Set up Ruby + # To automatically get bug fixes and new Ruby versions for ruby/setup-ruby, + # change this to (see https://github.com/ruby/setup-ruby#versioning): + # uses: ruby/setup-ruby@v1 + uses: ruby/setup-ruby@v1 + with: + ruby-version: ${{ matrix.ruby-version }} + bundler-cache: true # runs 'bundle install' and caches installed gems automatically + bundler: 2.4 + - name: Run tests + run: bundle exec rspec diff --git a/Gemfile b/Gemfile index 3d027e6..6ecb5b1 100644 --- a/Gemfile +++ b/Gemfile @@ -3,7 +3,8 @@ source 'https://rubygems.org' gemspec group :development do - gem 'activerecord' + gem 'activerecord', '~>4.2.11.3' + gem 'bigdecimal', '~>1.4.0' gem 'bson_ext' gem 'guard' gem 'guard-rspec' @@ -13,5 +14,5 @@ group :development do gem 'rake' gem 'RedCloth' gem 'rspec' - gem 'sqlite3' + gem 'sqlite3', '~> 1.3.0' end diff --git a/Gemfile.lock b/Gemfile.lock index b9d59cb..0468c21 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -6,99 +6,102 @@ PATH GEM remote: https://rubygems.org/ specs: - RedCloth (4.2.9) - activemodel (4.1.4) - activesupport (= 4.1.4) + RedCloth (4.3.3) + activemodel (4.2.11.3) + activesupport (= 4.2.11.3) builder (~> 3.1) - activerecord (4.1.4) - activemodel (= 4.1.4) - activesupport (= 4.1.4) - arel (~> 5.0.0) - activesupport (4.1.4) - i18n (~> 0.6, >= 0.6.9) - json (~> 1.7, >= 1.7.7) + activerecord (4.2.11.3) + activemodel (= 4.2.11.3) + activesupport (= 4.2.11.3) + arel (~> 6.0) + activesupport (4.2.11.3) + i18n (~> 0.7) minitest (~> 5.1) - thread_safe (~> 0.1) + thread_safe (~> 0.3, >= 0.3.4) tzinfo (~> 1.1) - arel (5.0.1.20140414130214) - bson (2.3.0) + arel (6.0.4) + bigdecimal (1.4.4) + bson (4.15.0) bson_ext (1.5.1) - builder (3.2.2) - celluloid (0.15.2) - timers (~> 1.1.0) - coderay (1.1.0) - connection_pool (2.0.0) - diff-lcs (1.2.5) - ffi (1.9.3) - formatador (0.2.5) - guard (2.6.1) + builder (3.2.4) + coderay (1.1.3) + concurrent-ruby (1.2.2) + diff-lcs (1.5.0) + ffi (1.16.3) + formatador (1.1.0) + guard (2.18.1) formatador (>= 0.2.4) - listen (~> 2.7) - lumberjack (~> 1.0) - pry (>= 0.9.12) + listen (>= 2.7, < 4.0) + lumberjack (>= 1.0.12, < 2.0) + nenv (~> 0.1) + notiffany (~> 0.0) + pry (>= 0.13.0) + shellany (~> 0.0) thor (>= 0.18.1) - guard-rspec (4.2.10) + guard-compat (1.2.1) + guard-rspec (4.7.3) guard (~> 2.1) - rspec (>= 2.14, < 4.0) - guard-yard (2.1.1) + guard-compat (~> 1.1) + rspec (>= 2.99.0, < 4.0) + guard-yard (2.2.1) guard (>= 1.1.0) yard (>= 0.7.0) - i18n (0.6.11) - json (1.8.1) - listen (2.7.9) - celluloid (>= 0.15.2) - rb-fsevent (>= 0.9.3) - rb-inotify (>= 0.9) - lumberjack (1.0.9) - method_source (0.8.2) - minitest (5.4.0) - mongoid (4.0.0) + i18n (0.9.5) + concurrent-ruby (~> 1.0) + listen (3.8.0) + rb-fsevent (~> 0.10, >= 0.10.3) + rb-inotify (~> 0.9, >= 0.9.10) + lumberjack (1.2.10) + method_source (1.0.0) + minitest (5.20.0) + mongo (2.19.3) + bson (>= 4.14.1, < 5.0.0) + mongoid (5.4.1) activemodel (~> 4.0) - moped (~> 2.0.0) - origin (~> 2.1) + mongo (>= 2.5.1, < 3.0.0) + origin (~> 2.3) tzinfo (>= 0.3.37) - moped (2.0.0) - bson (~> 2.2) - connection_pool (~> 2.0) - optionable (~> 0.2.0) - optionable (0.2.0) - origin (2.1.1) - pry (0.10.0) - coderay (~> 1.1.0) - method_source (~> 0.8.1) - slop (~> 3.4) - rake (10.3.2) - rb-fsevent (0.9.4) - rb-inotify (0.9.5) - ffi (>= 0.5.0) - rspec (3.0.0) - rspec-core (~> 3.0.0) - rspec-expectations (~> 3.0.0) - rspec-mocks (~> 3.0.0) - rspec-core (3.0.2) - rspec-support (~> 3.0.0) - rspec-expectations (3.0.2) + nenv (0.3.0) + notiffany (0.1.3) + nenv (~> 0.1) + shellany (~> 0.0) + origin (2.3.1) + pry (0.14.2) + coderay (~> 1.1) + method_source (~> 1.0) + rake (13.1.0) + rb-fsevent (0.11.2) + rb-inotify (0.10.1) + ffi (~> 1.0) + rspec (3.12.0) + rspec-core (~> 3.12.0) + rspec-expectations (~> 3.12.0) + rspec-mocks (~> 3.12.0) + rspec-core (3.12.2) + rspec-support (~> 3.12.0) + rspec-expectations (3.12.3) + diff-lcs (>= 1.2.0, < 2.0) + rspec-support (~> 3.12.0) + rspec-mocks (3.12.6) diff-lcs (>= 1.2.0, < 2.0) - rspec-support (~> 3.0.0) - rspec-mocks (3.0.2) - rspec-support (~> 3.0.0) - rspec-support (3.0.2) - slop (3.5.0) - sqlite3 (1.3.9) - thor (0.19.1) - thread_safe (0.3.4) - timers (1.1.0) - tzinfo (1.2.1) + rspec-support (~> 3.12.0) + rspec-support (3.12.1) + shellany (0.0.1) + sqlite3 (1.3.13) + thor (1.3.0) + thread_safe (0.3.6) + tzinfo (1.2.11) thread_safe (~> 0.1) - yard (0.8.7.4) + yard (0.9.34) PLATFORMS ruby DEPENDENCIES RedCloth - activerecord + activerecord (~> 4.2.11.3) attribute_normalizer! + bigdecimal (~> 1.4.0) bson_ext guard guard-rspec @@ -107,4 +110,7 @@ DEPENDENCIES pry rake rspec - sqlite3 + sqlite3 (~> 1.3.0) + +BUNDLED WITH + 2.4.10