Skip to content

Commit

Permalink
fixing ordering dependent specs
Browse files Browse the repository at this point in the history
  • Loading branch information
bbenezech committed Jan 16, 2012
1 parent 3f25fc7 commit 19453d7
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 0 deletions.
1 change: 1 addition & 0 deletions lib/rails_admin/config.rb
Expand Up @@ -259,6 +259,7 @@ def reset
@default_hidden_fields[:show] = [:id, :created_at, :created_on, :deleted_at, :updated_at, :updated_on, :deleted_on]
@default_items_per_page = 20
@default_search_operator = 'default'
@attr_accessible_role = nil
@excluded_models = []
@included_models = []
@total_columns_width = 697
Expand Down
4 changes: 4 additions & 0 deletions spec/lib/rails_admin_spec.rb
Expand Up @@ -15,6 +15,10 @@
end

describe ".add_extension" do
before do
RailsAdmin::EXTENSIONS = []
end

it "registers the extension with RailsAdmin" do
RailsAdmin.add_extension(:example, ExampleModule)
RailsAdmin::EXTENSIONS.select { |name| name == :example }.length.should == 1
Expand Down
4 changes: 4 additions & 0 deletions spec/requests/config/edit/rails_admin_config_edit_spec.rb
Expand Up @@ -508,6 +508,10 @@ class Team
@time = ::Time.now.getutc
end

after(:each) do
Time.zone = 'UTC'
end

describe "a datetime field" do

it "should default to %B %d, %Y %H:%M" do
Expand Down

0 comments on commit 19453d7

Please sign in to comment.