Sha256: 35e36b036d5b6b3e63c01a9333e21fa78000de5354a4d4231d7d2cccff3bacbd

Contents?: true

Size: 747 Bytes

Versions: 10

Compression:

Stored size: 747 Bytes

Contents

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

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

puts "VERSION: " + DBRC::XML::VERSION

# Use the .dbrc file in this directory
db1 = DBRC::XML.new("foo",nil,Dir.pwd) # Get first entry found for 'foo'
db2 = DBRC::XML.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

10 entries across 10 versions & 1 rubygems

Version Path
dbi-dbrc-1.4.0-x86-mingw32 examples/xml/test_xml.rb
dbi-dbrc-1.3.0-x86-mingw32 examples/xml/test_xml.rb
dbi-dbrc-1.1.9-x86-mingw32 examples/xml/test_xml.rb
dbi-dbrc-1.1.8-x86-mingw32 examples/xml/test_xml.rb
dbi-dbrc-1.1.7-x86-mingw32 examples/xml/test_xml.rb
dbi-dbrc-1.1.6-x86-mswin32-60 examples/xml/test_xml.rb
dbi-dbrc-1.1.2 examples/xml/test_xml.rb
dbi-dbrc-1.1.3-x86-mswin32-60 examples/xml/test_xml.rb
dbi-dbrc-1.1.3 examples/xml/test_xml.rb
dbi-dbrc-1.1.2-x86-mswin32-60 examples/xml/test_xml.rb