diff --git a/scenario/known-issues/constant-path.rb b/scenario/known-issues/constant-path.rb new file mode 100644 index 000000000..c492abae4 --- /dev/null +++ b/scenario/known-issues/constant-path.rb @@ -0,0 +1,43 @@ +## update: test.rb +module Baz + module Foo + class Bar < ::Foo::Bar + end + end +end + +module Foo + class Bar + end +end + +## assert: test.rb +module Baz + module Foo + class Bar < ::Foo::Bar + end + end +end + +module Foo + class Bar + end +end + +## update: test.rb +class Foo +end + +module Bar + class Foo < Foo + end +end + +## assert: test.rb +class Foo +end + +module Bar + class Foo < ::Foo + end +end diff --git a/scenario/known-issues/struct.rb b/scenario/known-issues/struct.rb new file mode 100644 index 000000000..5f3119909 --- /dev/null +++ b/scenario/known-issues/struct.rb @@ -0,0 +1,20 @@ +## update: test.rb +Foo = Struct.new(:foo) do + def foo? + !!foo + end + + private + + def not_foo? + !foo + end +end + +## assert: test.rb +class Foo < Struct[untyped] + def foo: -> untyped + def foo?: -> bool + private + def not_foo?: -> bool +end