Add bin and edit workflow
Gitea Actions Demo / Explore-Gitea-Actions (push) Failing after 9s

This commit is contained in:
2026-09-16 13:11:16 -06:00
parent c8ac4fcae5
commit 4cee170d66
17576 changed files with 895740 additions and 2 deletions
@@ -0,0 +1,60 @@
require 'facets/cloneable'
test_case Cloneable do
foo = Class.new do
include Cloneable
def initialize
@bar=[]
end
def bar_id
@bar.object_id
end
end
method :dup do
test do
a = foo.new
b = a.dup
a.bar_id.refute == b.bar_id
end
test "tainted" do
a = foo.new
a.taint
b = a.dup
b.assert.tainted?
end
test "frozen" do
a = foo.new
a.freeze
b = a.dup
b.refute.frozen?
end
end
method :clone do
test do
a = foo.new
b = a.clone
assert(a.bar_id != b.bar_id, "should not be equal")
end
test "tainted" do
a = foo.new
a.taint
b = a.clone
assert b.tainted?, "b should be tainted"
end
test "frozen" do
a = foo.new
a.freeze
b = a.clone
assert b.frozen?, "b should be frozen"
end
end
end