Skip to content

Commit

Permalink
Add tags for failing core specs
Browse files Browse the repository at this point in the history
  • Loading branch information
eregon committed Nov 6, 2020
1 parent 107863c commit 48cb4bd
Show file tree
Hide file tree
Showing 56 changed files with 130 additions and 0 deletions.
1 change: 1 addition & 0 deletions spec/tags/core/array/deconstruct_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
fails:Array#deconstruct returns self
1 change: 1 addition & 0 deletions spec/tags/core/array/join_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
fails:Array#join when $, is not nil warns
1 change: 1 addition & 0 deletions spec/tags/core/binding/irb_tags.txt
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
slow:Binding#irb creates an IRB session with the binding in scope
fails:Binding#irb creates an IRB session with the binding in scope
3 changes: 3 additions & 0 deletions spec/tags/core/comparable/clamp_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
fails:Comparable#clamp returns self if within the given range parameters
fails:Comparable#clamp returns the minimum value of the range parameters if smaller than it
fails:Comparable#clamp returns the maximum value of the range parameters if greater than it
3 changes: 3 additions & 0 deletions spec/tags/core/complex/comparision_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
fails:Complex#<=> returns nil if either self or argument has imaginary part
fails:Complex#<=> returns nil if argument is not numeric
fails:Complex#<=> returns 0, 1, or -1 if self and argument do not have imaginary part
1 change: 1 addition & 0 deletions spec/tags/core/dir/element_reference_tags.txt
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
fails:Dir.[] splits the string on \0 if there is only one string given and warns
fails:Dir.[] raises an ArgumentError if the string contains \0
1 change: 1 addition & 0 deletions spec/tags/core/dir/glob_tags.txt
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
fails:Dir.glob splits the string on \0 if there is only one string given and warns
fails:Dir.glob raises an ArgumentError if the string contains \0
1 change: 1 addition & 0 deletions spec/tags/core/encoding/list_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
fails:Encoding.list includes CESU-8 encoding
3 changes: 3 additions & 0 deletions spec/tags/core/enumerable/filter_map_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
fails:Enumerable#filter_map returns an empty array if there are no elements
fails:Enumerable#filter_map returns an array with truthy results of passing each element to block
fails:Enumerable#filter_map returns an enumerator when no block given
5 changes: 5 additions & 0 deletions spec/tags/core/enumerable/tally_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
fails:Enumerable#tally returns a hash with counts according to the value
fails:Enumerable#tally returns a hash without default
fails:Enumerable#tally returns an empty hash for empty enumerables
fails:Enumerable#tally counts values as gathered array when yielded with multiple arguments
fails:Enumerable#tally does not call given block
2 changes: 2 additions & 0 deletions spec/tags/core/enumerator/lazy/eager_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
fails:Enumerator::Lazy#eager returns a non-lazy Enumerator converted from the lazy enumerator
fails:Enumerator::Lazy#eager does not enumerate an enumerator
1 change: 1 addition & 0 deletions spec/tags/core/enumerator/new_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
fails:Enumerator.new when passed a block defines iteration with block, yielder argument and treating it as a proc
4 changes: 4 additions & 0 deletions spec/tags/core/enumerator/produce_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
fails:Enumerator.produce creates an infinite enumerator
fails:Enumerator.produce terminates iteration when block raises StopIteration exception
fails:Enumerator.produce when initial value skipped uses nil instead
fails:Enumerator.produce when initial value skipped starts enumerable from result of first block call
1 change: 1 addition & 0 deletions spec/tags/core/enumerator/yielder/to_proc_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
fails:Enumerator::Yielder#to_proc returns a Proc object that takes an argument and yields it to the block
2 changes: 2 additions & 0 deletions spec/tags/core/exception/frozen_error_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
fails:FrozenError.new should take optional receiver argument
fails:FrozenError#receiver should return frozen object that modification was attempted on
2 changes: 2 additions & 0 deletions spec/tags/core/false/to_s_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
fails:FalseClass#to_s returns a frozen string
fails:FalseClass#to_s always returns the same string
1 change: 1 addition & 0 deletions spec/tags/core/file/extname_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
fails:File.extname for a filename ending with a dot returns '.'
1 change: 1 addition & 0 deletions spec/tags/core/hash/constructor_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
fails:Hash.[] raises for elements that are not arrays
3 changes: 3 additions & 0 deletions spec/tags/core/hash/deconstruct_keys_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
fails:Hash#deconstruct_keys returns self
fails:Hash#deconstruct_keys requires one argument
fails:Hash#deconstruct_keys ignores argument
1 change: 1 addition & 0 deletions spec/tags/core/integer/chr_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
fails:Integer#chr with an encoding argument returns a String encoding self interpreted as a codepoint in the CESU-8 encoding
13 changes: 13 additions & 0 deletions spec/tags/core/integer/element_reference_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
fails:Integer#[] fixnum when index and length passed returns specified number of bits from specified position
fails:Integer#[] fixnum when index and length passed ensures n[i, len] equals to (n >> i) & ((1 << len) - 1)
fails:Integer#[] fixnum when index and length passed moves start position to the most significant bits when negative index passed
fails:Integer#[] fixnum when index and length passed ignores negative length
fails:Integer#[] fixnum when range passed returns bits specified by range
fails:Integer#[] fixnum when range passed ensures n[i..j] equals to (n >> i) & ((1 << (j - i + 1)) - 1)
fails:Integer#[] fixnum when range passed ensures n[i..] equals to (n >> i)
fails:Integer#[] fixnum when range passed moves lower boundary to the most significant bits when negative value passed
fails:Integer#[] fixnum when range passed ignores negative upper boundary
fails:Integer#[] fixnum when range passed ignores upper boundary smaller than lower boundary
fails:Integer#[] fixnum when range passed raises FloatDomainError if any boundary is infinity
fails:Integer#[] fixnum when range passed when passed (..i) returns 0 if all i bits equal 0
fails:Integer#[] fixnum when range passed when passed (..i) raises ArgumentError if any of i bit equals 1
1 change: 1 addition & 0 deletions spec/tags/core/kernel/proc_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
fails:Kernel#proc can be created when called with no block
2 changes: 2 additions & 0 deletions spec/tags/core/kernel/require_tags.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,5 @@ slow:Kernel#require ($LOADED_FEATURES) complex, enumerator, rational and thread
slow:Kernel.require ($LOADED_FEATURES) complex, enumerator, rational and thread are already required
slow:Kernel#require ($LOADED_FEATURES) unicode_normalize is part of core and not $LOADED_FEATURES
slow:Kernel.require ($LOADED_FEATURES) unicode_normalize is part of core and not $LOADED_FEATURES
fails:Kernel#require (non-extensioned path) loads a .rb extensioned file when a C-extension file exists on an earlier load path
fails:Kernel#require (non-extensioned path) does not load a feature twice when $LOAD_PATH has been modified
2 changes: 2 additions & 0 deletions spec/tags/core/kernel/taint_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
fails:Kernel#taint is a no-op
fails:Kernel#taint warns in verbose mode
2 changes: 2 additions & 0 deletions spec/tags/core/kernel/tainted_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
fails:Kernel#tainted? is a no-op
fails:Kernel#tainted? warns in verbose mode
2 changes: 2 additions & 0 deletions spec/tags/core/kernel/trust_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
fails:Kernel#trust is a no-op
fails:Kernel#trust warns in verbose mode
2 changes: 2 additions & 0 deletions spec/tags/core/kernel/untaint_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
fails:Kernel#untaint is a no-op
fails:Kernel#untaint warns in verbose mode
2 changes: 2 additions & 0 deletions spec/tags/core/kernel/untrust_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
fails:Kernel#untrust is a no-op
fails:Kernel#untrust warns in verbose mode
2 changes: 2 additions & 0 deletions spec/tags/core/kernel/untrusted_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
fails:Kernel#untrusted? is a no-op
fails:Kernel#untrusted? warns in verbose mode
4 changes: 4 additions & 0 deletions spec/tags/core/method/compose_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
fails:Method#<< raises TypeError if passed not callable object
fails:Method#<< does not try to coerce argument with #to_proc
fails:Method#>> raises TypeError if passed not callable object
fails:Method#>> does not try to coerce argument with #to_proc
1 change: 1 addition & 0 deletions spec/tags/core/method/inspect_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
fails:Method#inspect returns a String containing method arguments
1 change: 1 addition & 0 deletions spec/tags/core/method/to_s_tags.txt
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
fails:Method#to_s returns a String containing the singleton class if method is defined in the singleton class
fails:Method#to_s returns a String containing method arguments
2 changes: 2 additions & 0 deletions spec/tags/core/module/autoload_tags.txt
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
fails:Module#autoload (concurrently) blocks others threads while doing an autoload
fails:Module#autoload? returns nil if an ancestor defined that autoload but recursion is disabled
fails:Module#autoload? returns the name of the file that will be loaded if recursion is disabled but the autoload is defined on the class itself
2 changes: 2 additions & 0 deletions spec/tags/core/module/name_tags.txt
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
fails:Module#name returns nil for a singleton class
fails:Module#name returns a frozen String
fails:Module#name always returns the same String for a given Module
1 change: 1 addition & 0 deletions spec/tags/core/module/refine_tags.txt
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
slow:Module#refine method lookup looks in the included modules for builtin methods
fails:Module#refine for methods accessed indirectly is honored by Kernel#method
2 changes: 2 additions & 0 deletions spec/tags/core/nil/to_s_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
fails:NilClass#to_s returns a frozen string
fails:NilClass#to_s always returns the same string
1 change: 1 addition & 0 deletions spec/tags/core/objectspace/weakmap/element_set_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
fails:ObjectSpace::WeakMap#[]= accepts primitive or frozen keys or values
1 change: 1 addition & 0 deletions spec/tags/core/objectspace/weakmap/include_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
fails:ObjectSpace::WeakMap#include? reports true if the pair exists and the value is nil
1 change: 1 addition & 0 deletions spec/tags/core/objectspace/weakmap/key_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
fails:ObjectSpace::WeakMap#key? reports true if the pair exists and the value is nil
1 change: 1 addition & 0 deletions spec/tags/core/objectspace/weakmap/member_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
fails:ObjectSpace::WeakMap#member? reports true if the pair exists and the value is nil
4 changes: 4 additions & 0 deletions spec/tags/core/proc/compose_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
fails:Proc#<< raises TypeError if passed not callable object
fails:Proc#<< does not try to coerce argument with #to_proc
fails:Proc#>> raises TypeError if passed not callable object
fails:Proc#>> does not try to coerce argument with #to_proc
3 changes: 3 additions & 0 deletions spec/tags/core/proc/inspect_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
fails:Proc#inspect for a proc created with Proc.new returns a description including file and line number
fails:Proc#inspect for a proc created with lambda returns a description including '(lambda)' and including file and line number
fails:Proc#inspect for a proc created with proc returns a description including file and line number
3 changes: 3 additions & 0 deletions spec/tags/core/proc/new_tags.txt
Original file line number Diff line number Diff line change
@@ -1 +1,4 @@
fails:Proc.new with an associated block raises a LocalJumpError when context of the block no longer exists
fails:Proc.new without a block can be created if invoked from within a method with a block
fails:Proc.new without a block can be created if invoked on a subclass from within a method with a block
fails:Proc.new without a block can be create when called with no block
3 changes: 3 additions & 0 deletions spec/tags/core/proc/to_s_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
fails:Proc#to_s for a proc created with Proc.new returns a description including file and line number
fails:Proc#to_s for a proc created with lambda returns a description including '(lambda)' and including file and line number
fails:Proc#to_s for a proc created with proc returns a description including file and line number
2 changes: 2 additions & 0 deletions spec/tags/core/range/new_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
fails:Range.new beginless/endless range allows beginless left boundary
fails:Range.new beginless/endless range distinguishes ranges with included and excluded right boundary
1 change: 1 addition & 0 deletions spec/tags/core/string/split_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
fails:String#split with String when $; is not nil warns
8 changes: 8 additions & 0 deletions spec/tags/core/struct/deconstruct_keys_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
fails:Struct#deconstruct_keys returns a hash of attributes
fails:Struct#deconstruct_keys requires one argument
fails:Struct#deconstruct_keys returns only specified keys
fails:Struct#deconstruct_keys accepts string attribute names
fails:Struct#deconstruct_keys accepts argument position number as well but returns them as keys
fails:Struct#deconstruct_keys ignores not existing attribute names
fails:Struct#deconstruct_keys accepts nil argument and return all the attributes
fails:Struct#deconstruct_keys raise TypeError if passed anything accept nil or array
1 change: 1 addition & 0 deletions spec/tags/core/struct/deconstruct_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
fails:Struct#deconstruct returns an array of attribute values
1 change: 1 addition & 0 deletions spec/tags/core/thread/inspect_tags.txt
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
fails:Thread#inspect has a binary encoding
fails:Thread#inspect returns a description including file and line number
1 change: 1 addition & 0 deletions spec/tags/core/thread/to_s_tags.txt
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
fails:Thread#to_s has a binary encoding
fails:Thread#to_s returns a description including file and line number
7 changes: 7 additions & 0 deletions spec/tags/core/time/ceil_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
fails:Time#ceil defaults to ceiling to 0 places
fails:Time#ceil ceils to 0 decimal places with an explicit argument
fails:Time#ceil ceils to 2 decimal places with an explicit argument
fails:Time#ceil ceils to 4 decimal places with an explicit argument
fails:Time#ceil ceils to 7 decimal places with an explicit argument
fails:Time#ceil returns an instance of Time, even if #ceil is called on a subclass
fails:Time#ceil copies own timezone to the returning value
5 changes: 5 additions & 0 deletions spec/tags/core/time/floor_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
fails:Time#floor defaults to flooring to 0 places
fails:Time#floor floors to 0 decimal places with an explicit argument
fails:Time#floor floors to 7 decimal places with an explicit argument
fails:Time#floor returns an instance of Time, even if #floor is called on a subclass
fails:Time#floor copies own timezone to the returning value
2 changes: 2 additions & 0 deletions spec/tags/core/time/inspect_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
fails:Time#inspect preserves milliseconds
fails:Time#inspect formats nanoseconds as a Rational
2 changes: 2 additions & 0 deletions spec/tags/core/true/to_s_tags.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
fails:TrueClass#to_s returns a frozen string
fails:TrueClass#to_s always returns the same string
1 change: 1 addition & 0 deletions spec/tags/core/warning/element_reference_tags.txt
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
slow:Warning.[] returns default values for categories :deprecated and :experimental
fails:Warning.[] raises for unknown category
3 changes: 3 additions & 0 deletions spec/tags/core/warning/element_set_tags.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,5 @@
slow:Warning.[]= emits and suppresses warnings for :deprecated
slow:Warning.[]= emits and suppresses warnings for :experimental
fails:Warning.[]= raises for unknown category
fails:Warning.[]= emits and suppresses warnings for :deprecated
fails:Warning.[]= emits and suppresses warnings for :experimental

0 comments on commit 48cb4bd

Please sign in to comment.