Rspec 3.0 support

This commit is contained in:
erwanlr
2014-06-02 22:06:49 +02:00
parent c12b1d0670
commit c8c126d444
55 changed files with 338 additions and 336 deletions

View File

@@ -29,22 +29,22 @@ describe WpTheme do
let(:theme_path) { 'wp-content/themes/theme-name/' }
describe '#allowed_options' do
its(:allowed_options) { should include :style_url }
its(:allowed_options) { is_expected.to include :style_url }
end
describe '#forge_uri' do
its(:uri) { should == uri.merge(theme_path) }
its(:uri) { is_expected.to eq uri.merge(theme_path) }
end
describe '#style_url' do
its(:style_url) { should == uri.merge(theme_path + '/style.css').to_s }
its(:style_url) { is_expected.to eq uri.merge(theme_path + '/style.css').to_s }
context 'when its already set' do
it 'returns it instead of the default one' do
url = uri.merge(theme_path + '/custom.css').to_s
wp_theme.style_url = url
wp_theme.style_url.should == url
expect(wp_theme.style_url).to eq url
end
end
end