class Crowbar::Mutators::BoundaryNumbers

Overview

Replaces textual integers or floats with boundary values (underflow, overflow, off-by-one)

Defined in:

crowbar/mutators/values.cr

Constant Summary

BOUNDARIES = ["0", "1", "-1", "2", "-2", "127", "128", "-128", "-129", "255", "256", "-256", "32767", "32768", "-32768", "-32769", "65535", "65536", "2147483647", "2147483648", "-2147483648", "-2147483649", "4294967295", "4294967296", "9007199254740991", "9007199254740992", "9223372036854775807", "9223372036854775808", "-9223372036854775808", "18446744073709551615", "NaN", "+Infinity", "-Infinity", "0.0", "-0.0", "1e308", "1e-308"]

Instance Method Summary

Instance methods inherited from class Crowbar::Mutator

adjust_score(delta : Int32) adjust_score, aliases : Array(String) aliases, description : String description, effective_weight : Float64 effective_weight, mutate(context : Context, buffer : Buffer, target_range : Tuple(Int32, Int32) | Nil = nil) : Tuple(Bool, Int32) mutate, name : String name, score : Int32 score, score=(score : Int32) score=, weight : Float64 weight, weight=(weight : Float64) weight=

Constructor methods inherited from class Crowbar::Mutator

new(weight : Float64 = 1.0) new

Instance Method Detail

def description : String #

def mutate(context : Context, buffer : Buffer, target_range : Tuple(Int32, Int32) | Nil = nil) : Tuple(Bool, Int32) #

def name : String #