Sha256: eada1d8c7bc29868259ec585563706f5ffb42fd5031f8eb39cda2d9d13233f35

Contents?: true

Size: 719 Bytes

Versions: 12

Compression:

Stored size: 719 Bytes

Contents

#######################################################################
# test_xml.rb
#
# Simple test script that uses the DBRC::XML subclass.
#######################################################################
if File.basename(Dir.pwd) == "yml"
   Dir.chdir "../.."
   $LOAD_PATH.unshift Dir.pwd + "/lib"
   Dir.chdir "examples/yml"
end

require "dbi/dbrc"
require "pp"
include DBI

puts "VERSION: " + DBRC::YML::VERSION

# Use the .dbrc file in this directory
db1 = DBRC::YML.new("foo",nil,Dir.pwd) # Get first entry found for 'foo'
db2 = DBRC::YML.new("foo","user1",Dir.pwd) # Specify user

puts "First entry found for 'foo': "
pp db1
puts "=" * 20

puts "Entry for 'foo' with user 'bar': "
pp db2
puts "=" * 20

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
dbi-dbrc-1.3.0 examples/yml/test_yml.rb
dbi-dbrc-1.2.0 examples/yml/test_yml.rb
dbi-dbrc-1.1.9 examples/yml/test_yml.rb
dbi-dbrc-1.1.8 examples/yml/test_yml.rb
dbi-dbrc-1.1.7 examples/yml/test_yml.rb
dbi-dbrc-1.1.6 examples/yml/test_yml.rb
dbi-dbrc-1.1.5 examples/yml/test_yml.rb
dbi-dbrc-1.1.0 examples/yml/test_yml.rb
dbi-dbrc-1.0.0 examples/yml/test_yml.rb
dbi-dbrc-1.1.1 examples/yml/test_yml.rb
dbi-dbrc-1.1.4 examples/yml/test_yml.rb
dbi-dbrc-1.0.1 examples/yml/test_yml.rb