Sha256: 3f0501bcf063fc4190b7c6ee1a2700c4978936d00d953af3f6fceffc0ad87640

Contents?: true

Size: 225 Bytes

Versions: 1

Compression:

Stored size: 225 Bytes

Contents

class String
  
  #
  # "Watir::Span" => "Span"
  # 
  
  def demodulize
    gsub(/^.*::/, '')
  end
  
  #
  # "FooBar" => "foo_bar"
  # 
  
  def underscore
    gsub(/\B[A-Z][^A-Z]/, '_\&').downcase.gsub(' ', '_')
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
watir-1.6.5 lib/watir/core_ext.rb