diff options
Diffstat (limited to 'spec/ruby/core/thread/backtrace/location/fixtures/classes.rb')
-rw-r--r-- | spec/ruby/core/thread/backtrace/location/fixtures/classes.rb | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/spec/ruby/core/thread/backtrace/location/fixtures/classes.rb b/spec/ruby/core/thread/backtrace/location/fixtures/classes.rb new file mode 100644 index 0000000000..3e42d8cf81 --- /dev/null +++ b/spec/ruby/core/thread/backtrace/location/fixtures/classes.rb @@ -0,0 +1,17 @@ +module ThreadBacktraceLocationSpecs + MODULE_LOCATION = caller_locations(0) rescue nil + + def self.locations + caller_locations + end + + def self.method_location + caller_locations(0) + end + + def self.block_location + 1.times do + return caller_locations(0) + end + end +end |