diff --git a/Gemfile b/Gemfile index 7cc5b67f4..3c76de87f 100644 --- a/Gemfile +++ b/Gemfile @@ -23,7 +23,7 @@ gem 'rubyzip', '~> 2.3' gem 'espeak-ruby', '~> 1.1.0' # Text-to-Voice gem 'rake', '~> 13.1' # gem 'otr-activerecord', '~> 2.1', '>= 2.1.2' -gem 'otr-activerecord', '= 2.1.2' +gem 'otr-activerecord', '~> 2.2.0' gem 'sqlite3', '~> 1.6' gem 'rubocop', '~> 1.59.0', require: false diff --git a/Gemfile.lock b/Gemfile.lock index 6c7f9c2c3..42f1a75a1 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,17 +1,23 @@ GEM remote: https://rubygems.org/ specs: - activemodel (7.0.4.3) - activesupport (= 7.0.4.3) - activerecord (7.0.4.3) - activemodel (= 7.0.4.3) - activesupport (= 7.0.4.3) - activesupport (7.0.4.3) + activemodel (7.1.2) + activesupport (= 7.1.2) + activerecord (7.1.2) + activemodel (= 7.1.2) + activesupport (= 7.1.2) + timeout (>= 0.4.0) + activesupport (7.1.2) + base64 + bigdecimal concurrent-ruby (~> 1.0, >= 1.0.2) + connection_pool (>= 2.2.5) + drb i18n (>= 1.6, < 2) minitest (>= 5.1) + mutex_m tzinfo (~> 2.0) - addressable (2.8.4) + addressable (2.8.6) public_suffix (>= 2.0.2, < 6.0) ansi (1.5.0) archive-zip (0.12.0) @@ -23,8 +29,10 @@ GEM timers (~> 4.1) async-dns (1.3.0) async-io (~> 1.15) - async-io (1.34.3) + async-io (1.38.1) async + base64 (0.2.0) + bigdecimal (3.1.5) browserstack-local (1.4.3) byebug (11.1.3) capybara (3.39.2) @@ -38,13 +46,16 @@ GEM xpath (~> 3.2) coderay (1.1.3) concurrent-ruby (1.2.2) - console (1.16.2) + connection_pool (2.4.1) + console (1.23.3) + fiber-annotation fiber-local curb (1.0.5) daemons (1.4.1) diff-lcs (1.5.0) - domain_name (0.5.20190701) - unf (>= 0.0.5, < 1.0.0) + domain_name (0.6.20231109) + drb (2.2.0) + ruby2_keywords em-websocket (0.5.3) eventmachine (>= 0.12.9) http_parser.rb (~> 0) @@ -53,6 +64,7 @@ GEM event_emitter (0.2.6) eventmachine (1.2.7) execjs (2.9.1) + fiber-annotation (0.2.0) fiber-local (1.0.0) geckodriver-helper (0.24.0) archive-zip (~> 0.7) @@ -63,41 +75,44 @@ GEM http-cookie (1.0.5) domain_name (~> 0.5) http_parser.rb (0.8.0) - i18n (1.12.0) + i18n (1.14.1) concurrent-ruby (~> 1.0) io-console (0.7.1) io-like (0.3.1) irb (1.11.0) rdoc reline (>= 0.3.8) - json (2.6.3) + json (2.7.1) language_server-protocol (3.17.0.3) matrix (0.4.2) maxmind-db (1.2.0) method_source (1.0.0) - mime-types (3.4.1) + mime-types (3.5.1) mime-types-data (~> 3.2015) - mime-types-data (3.2023.0218.1) - mini_mime (1.1.2) - minitest (5.18.0) - mojo_magick (0.6.7) + mime-types-data (3.2023.1205) + mini_mime (1.1.5) + minitest (5.20.0) + mojo_magick (0.6.8) msfrpc-client (1.1.2) msgpack (~> 1) - msgpack (1.6.1) + msgpack (1.7.2) mustermann (3.0.0) ruby2_keywords (~> 0.0.1) - net-protocol (0.2.1) + mutex_m (0.2.0) + net-protocol (0.2.2) timeout net-smtp (0.4.0) net-protocol netrc (0.11.0) - nio4r (2.5.8) - nokogiri (1.15.2-arm64-darwin) + nio4r (2.7.0) + nokogiri (1.16.0-aarch64-linux) racc (~> 1.4) - nokogiri (1.15.2-x86_64-linux) + nokogiri (1.16.0-arm64-darwin) racc (~> 1.4) - otr-activerecord (2.1.2) - activerecord (>= 4.0, < 7.1) + nokogiri (1.16.0-x86_64-linux) + racc (~> 1.4) + otr-activerecord (2.2.0) + activerecord (>= 4.0, < 7.2) hashie-forbidden_attributes (~> 0.1) parallel (1.24.0) parseconfig (1.1.2) @@ -113,12 +128,12 @@ GEM pry (>= 0.13, < 0.15) psych (5.1.2) stringio - public_suffix (5.0.1) - qr4r (0.6.1) + public_suffix (5.0.4) + qr4r (0.6.2) mojo_magick (~> 0.6.5) - rqrcode_core (~> 0.1) + rqrcode_core (~> 1.0) racc (1.7.3) - rack (2.2.7) + rack (2.2.8) rack-protection (3.0.6) rack rack-test (2.1.0) @@ -136,22 +151,23 @@ GEM mime-types (>= 1.16, < 4.0) netrc (~> 0.8) rexml (3.2.6) - rqrcode_core (0.2.0) + rqrcode_core (1.2.0) rr (3.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.1) + rspec-core (3.12.2) rspec-support (~> 3.12.0) - rspec-expectations (3.12.2) + rspec-expectations (3.12.3) diff-lcs (>= 1.2.0, < 2.0) rspec-support (~> 3.12.0) - rspec-mocks (3.12.4) + rspec-mocks (3.12.6) diff-lcs (>= 1.2.0, < 2.0) rspec-support (~> 3.12.0) - rspec-support (3.12.0) + rspec-support (3.12.1) rubocop (1.59.0) + base64 (~> 0.1.1) json (~> 2.3) language_server-protocol (>= 3.17.0) parallel (~> 1.10) @@ -180,13 +196,13 @@ GEM rack-protection (= 3.0.6) tilt (~> 2.0) slack-notifier (2.4.0) - sqlite3 (1.6.9-arm64-darwin) - sqlite3 (1.6.9-x86_64-linux) + sqlite3 (1.7.0-aarch64-linux) + sqlite3 (1.7.0-arm64-darwin) stringio (3.1.0) sync (0.5.0) term-ansicolor (1.7.1) tins (~> 1.0) - test-unit (3.5.7) + test-unit (3.6.1) power_assert test-unit-context (0.5.1) test-unit (>= 2.4.0) @@ -207,8 +223,8 @@ GEM daemons (~> 1.0, >= 1.0.9) eventmachine (~> 1.0, >= 1.0.4) rack (>= 1, < 3) - tilt (2.1.0) - timeout (0.4.0) + tilt (2.3.0) + timeout (0.4.1) timers (4.3.5) tins (1.32.1) sync @@ -216,9 +232,6 @@ GEM concurrent-ruby (~> 1.0) uglifier (4.2.0) execjs (>= 0.3.0, < 3) - unf (0.1.4) - unf_ext - unf_ext (0.0.8.2) unicode-display_width (2.5.0) webrick (1.8.1) websocket (1.2.10) @@ -231,7 +244,9 @@ GEM nokogiri (~> 1.8) PLATFORMS + aarch64-linux arm64-darwin-22 + arm64-darwin-23 x86_64-linux DEPENDENCIES @@ -253,7 +268,7 @@ DEPENDENCIES mime-types (~> 3.4, >= 3.4.1) msfrpc-client (~> 1.1, >= 1.1.2) net-smtp - otr-activerecord (= 2.1.2) + otr-activerecord (~> 2.2.0) parseconfig (~> 1.1, >= 1.1.2) pry-byebug (~> 3.10, >= 3.10.1) qr4r (~> 0.6.1) @@ -278,4 +293,4 @@ DEPENDENCIES xmlrpc (~> 0.3.3) BUNDLED WITH - 2.4.8 + 2.5.3 diff --git a/beef b/beef index cf6bd7216..ad0a22a9c 100755 --- a/beef +++ b/beef @@ -205,7 +205,7 @@ end # Migrate (if required) context = ActiveRecord::Migration.new.migration_context if context.needs_migration? - ActiveRecord::Migrator.new(:up, context.migrations, context.schema_migration).migrate + ActiveRecord::Migrator.new(:up, context.migrations, context.schema_migration, context.internal_metadata).migrate end # # @note Extensions may take a moment to load, thus we print out a please wait message diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index ac2c2aa4d..62d118ae1 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -51,8 +51,12 @@ if Gem.loaded_specs['otr-activerecord'].version > Gem::Version.create('1.4.2') OTR::ActiveRecord.establish_connection! end ActiveRecord::Schema.verbose = false + +# Migrate (if required) context = ActiveRecord::Migration.new.migration_context -ActiveRecord::Migrator.new(:up, context.migrations, context.schema_migration).migrate if context.needs_migration? +if context.needs_migration? + ActiveRecord::Migrator.new(:up, context.migrations, context.schema_migration, context.internal_metadata).migrate +end RSpec.configure do |config| config.disable_monkey_patching! @@ -65,6 +69,7 @@ RSpec.configure do |config| end config.around do |example| ActiveRecord::Base.transaction do + # byebug example.run raise ActiveRecord::Rollback end