#!/usr/bin/ruby -w
# Encoding: UTF-8
# frozen_string_literal: true
# =========================================================================== #
alias e puts
require 'colours'

# Testing code comes next:
e 'We will now test R,G,B values: 255,200,22'
p Colours::RGB[255,200,22]
begin
  p Colours::RGB[355,200,22]
rescue ArgumentError => error
  p error
  e 'We rescued this error however.'
end
_ = Colours::RGB.new '55,66,77'
e 'We will now test R,G,B values: 55,66,77'
p _
e 'Testing add(3) next:'
_.add 3
p _
e _.rgb
e
e 'Next, we will test HTML Colours (strings):'
e 'slateblue: → '+Colours::RGB['slateblue']
e 'darkblue:  → '+Colours::RGB['darkblue']
e '-------'
e 'Next, we will apply .lighten, from darkblue as our base colour:'
e Colours::RGB['darkblue']
e Colours::RGB.new(Colours::RGB['darkblue']).lighten # => "#232323"
e '-------'