diff options
author | Aaron Patterson <aaron.patterson@gmail.com> | 2011-05-10 10:31:34 -0700 |
---|---|---|
committer | Aaron Patterson <aaron.patterson@gmail.com> | 2011-05-23 15:06:12 -0700 |
commit | 74c5f65bfb7813cecb3a1e78b522de4586e76ac9 (patch) | |
tree | 2de057486e766e7d2fe0a2b677b6b55c9a768159 /activerecord | |
parent | ad3f0eec755d1d4dbe488eecf348f19dff6f58de (diff) | |
download | rails-74c5f65bfb7813cecb3a1e78b522de4586e76ac9.tar.gz rails-74c5f65bfb7813cecb3a1e78b522de4586e76ac9.tar.bz2 rails-74c5f65bfb7813cecb3a1e78b522de4586e76ac9.zip |
use top level file constant for join, etc
Diffstat (limited to 'activerecord')
-rw-r--r-- | activerecord/lib/active_record/fixtures.rb | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/activerecord/lib/active_record/fixtures.rb b/activerecord/lib/active_record/fixtures.rb index 16a30e3fdb..d8f88cf2be 100644 --- a/activerecord/lib/active_record/fixtures.rb +++ b/activerecord/lib/active_record/fixtures.rb @@ -478,7 +478,7 @@ module ActiveRecord connection, table_name, class_names[table_name.to_sym] || table_name.classify, - File.join(fixtures_directory, path)) + ::File.join(fixtures_directory, path)) end all_loaded_fixtures.update(fixtures_map) @@ -656,9 +656,9 @@ module ActiveRecord end def read_fixture_files - if File.file?(yaml_file_path) + if ::File.file?(yaml_file_path) read_yaml_fixture_files - elsif File.file?(csv_file_path) + elsif ::File.file?(csv_file_path) read_csv_fixture_files else raise FixturesFileNotFound, "Could not find #{yaml_file_path} or #{csv_file_path}" @@ -713,7 +713,7 @@ module ActiveRecord end def yaml_fixtures_key(path) - File.basename(@fixture_path).split(".").first + ::File.basename(@fixture_path).split(".").first end def parse_yaml_string(fixture_content) |