unittests/setup.rb in watir-1.6.6 vs unittests/setup.rb in watir-1.6.7.rc1
- old
+ new
@@ -8,10 +8,10 @@
# use local development versions of watir, firewatir, commonwatir if available
topdir = File.join(File.dirname(__FILE__), '..')
$firewatir_dev_lib = File.join(topdir, '..', 'firewatir', 'lib')
$watir_dev_lib = File.join(topdir, 'lib')
-commonwatir_dir = "commonwatir-#{File.read("VERSION").strip}" rescue "commonwatir"
+commonwatir_dir = "commonwatir#{File.exist?('VERSION') ? "-#{File.read('VERSION').strip}" : ""}"
commonwatir_absolute_dir = File.join(topdir, '..', commonwatir_dir)
libs = []
libs << File.join(commonwatir_absolute_dir, 'lib')
libs << commonwatir_absolute_dir # for the unit tests
libs.each { |lib| append_to_load_path(lib) }