summaryrefslogtreecommitdiff
path: root/spec/ruby/library/delegate/delegator/untaint_spec.rb
diff options
context:
space:
mode:
Diffstat (limited to 'spec/ruby/library/delegate/delegator/untaint_spec.rb')
-rw-r--r--spec/ruby/library/delegate/delegator/untaint_spec.rb26
1 files changed, 14 insertions, 12 deletions
diff --git a/spec/ruby/library/delegate/delegator/untaint_spec.rb b/spec/ruby/library/delegate/delegator/untaint_spec.rb
index ddcf854a43..3f8f7721a9 100644
--- a/spec/ruby/library/delegate/delegator/untaint_spec.rb
+++ b/spec/ruby/library/delegate/delegator/untaint_spec.rb
@@ -6,19 +6,21 @@ describe "Delegator#untaint" do
@delegate = -> { DelegateSpecs::Delegator.new("") }.call
end
- it "returns self" do
- @delegate.untaint.equal?(@delegate).should be_true
- end
+ ruby_version_is ''...'2.7' do
+ it "returns self" do
+ @delegate.untaint.equal?(@delegate).should be_true
+ end
- it "untaints the delegator" do
- @delegate.untaint
- @delegate.tainted?.should be_false
- # No additional meaningful test; that it does or not taint
- # "for real" the delegator has no consequence
- end
+ it "untaints the delegator" do
+ @delegate.untaint
+ @delegate.tainted?.should be_false
+ # No additional meaningful test; that it does or not taint
+ # "for real" the delegator has no consequence
+ end
- it "untaints the delegated object" do
- @delegate.untaint
- @delegate.__getobj__.tainted?.should be_false
+ it "untaints the delegated object" do
+ @delegate.untaint
+ @delegate.__getobj__.tainted?.should be_false
+ end
end
end