Last active
March 24, 2018 13:19
-
-
Save volkanunsal/885983978ad2d25684a1e850f22ab188 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Run options: --seed 15413 | |
# Running: | |
E | |
Error: | |
BugTest#test_association_stuff: | |
ArgumentError: unknown keyword: array | |
bin/rails test repro.rb:37 | |
Finished in 0.003746s, 266.9862 runs/s, 0.0000 assertions/s. | |
1 runs, 0 assertions, 0 failures, 1 errors, 0 skips |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# frozen_string_literal: true | |
begin | |
require "bundler/inline" | |
rescue LoadError => e | |
$stderr.puts "Bundler version 1.10 or later is required. Please update your Bundler" | |
raise e | |
end | |
gemfile(true) do | |
source "https://rubygems.org" | |
git_source(:github) { |repo| "https://github.com/#{repo}.git" } | |
gem 'rails', '5.1.5' | |
gem "pg" | |
gem "rgeo", '1.0.0' | |
gem 'activerecord-postgis-adapter', '~> 5.2' | |
end | |
require "active_record" | |
require "minitest/autorun" | |
require "logger" | |
# This connection will do for database-independent bug reports. | |
ActiveRecord::Base.establish_connection(adapter: "postgis", database: "postgres") | |
ActiveRecord::Base.logger = Logger.new(STDOUT) | |
ActiveRecord::Schema.define do | |
create_table :posts, force: true do |t| | |
end | |
end | |
class Post < ActiveRecord::Base | |
attribute :foo, :string, array: true | |
end | |
class BugTest < Minitest::Test | |
def test_association_stuff | |
assert_equal Post.attribute_names.include?('foo'), true | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment