added unit tests for checking debug value
setting default debug value during initializing
Fixed unit tests to work with Ruby 1.8.7 et al.