Class: Minitest::UntzLOL
Constant Summary collapse
- PI_3 =
:nodoc:
Math::PI / 3
Constants inherited from UntzIO
Minitest::UntzIO::ESC, Minitest::UntzIO::NND
Instance Attribute Summary
Attributes inherited from UntzIO
Instance Method Summary collapse
-
#initialize(io) ⇒ UntzLOL
constructor
:nodoc:.
- #untz(string) ⇒ Object
Methods inherited from UntzIO
#method_missing, #print, #puts, untz!, untz?
Constructor Details
#initialize(io) ⇒ UntzLOL
:nodoc:
94 95 96 97 98 99 100 101 102 103 104 105 |
# File 'lib/minitest/untz_plugin.rb', line 94 def initialize(io) # :nodoc: @colors = (0...(6 * 7)).map { |n| n *= 1.0 / 6 r = (3 * Math.sin(n ) + 3).to_i g = (3 * Math.sin(n + 2 * PI_3) + 3).to_i b = (3 * Math.sin(n + 4 * PI_3) + 3).to_i 36 * r + 6 * g + b + 16 } super end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Minitest::UntzIO