spec/normalizy/rspec/matcher/to_spec.rb in normalizy-0.2.0 vs spec/normalizy/rspec/matcher/to_spec.rb in normalizy-1.0.0
- old
+ new
@@ -1,18 +1,19 @@
# frozen_string_literal: true
require 'rails_helper'
RSpec.describe Normalizy::RSpec::Matcher, '.to' do
- let!(:matcher) { described_class.new :name }
- let!(:model) { User }
-
it 'caches the value' do
+ matcher = described_class.new(:downcase)
+
matcher.to :to
expect(matcher.instance_variable_get(:@to)).to eq :to
end
it 'returns it self' do
+ matcher = described_class.new(:downcase)
+
expect(matcher.to(:to)).to be matcher
end
end