spec/unit/sql_helper_spec.rb in lhm-2.1.0 vs spec/unit/sql_helper_spec.rb in lhm-2.2.0
- old
+ new
@@ -4,29 +4,29 @@
require File.expand_path(File.dirname(__FILE__)) + '/unit_helper'
require 'lhm/sql_helper'
describe Lhm::SqlHelper do
- it "should name index with a single column" do
+ it 'should name index with a single column' do
Lhm::SqlHelper.
idx_name(:users, :name).
- must_equal("index_users_on_name")
+ must_equal('index_users_on_name')
end
- it "should name index with multiple columns" do
+ it 'should name index with multiple columns' do
Lhm::SqlHelper.
idx_name(:users, [:name, :firstname]).
- must_equal("index_users_on_name_and_firstname")
+ must_equal('index_users_on_name_and_firstname')
end
- it "should name index with prefixed column" do
+ it 'should name index with prefixed column' do
Lhm::SqlHelper.
- idx_name(:tracks, ["title(10)", "album"]).
- must_equal("index_tracks_on_title_and_album")
+ idx_name(:tracks, ['title(10)', 'album']).
+ must_equal('index_tracks_on_title_and_album')
end
- it "should quote column names in index specification" do
+ it 'should quote column names in index specification' do
Lhm::SqlHelper.
- idx_spec(["title(10)", "album"]).
- must_equal("`title`(10), `album`")
+ idx_spec(['title(10)', 'album']).
+ must_equal('`title`(10), `album`')
end
end