Sha256: aef7231ca17004daadf53e41f00f34e57196011846d6da7237aea5017aef40ef

Contents?: true

Size: 1.69 KB

Versions: 2

Compression:

Stored size: 1.69 KB

Contents

# This file contains og initialization code for all tests. 
# This way you only change the parameters in one file in 
# order to run all the tests for many stores.
#
# Current store choices are
#  :mysql :psql :sqlite :kirby :memory

# CHANGE THIS TO SETUP MOST TESTS

configA = :mysql

# FOR MULTI-TESTS

configB = :mysql  

# SET THIS TO true TO ENABLE EXTRA DEBUG CODE

debug = false

# TO TEST AGAINST AN INSTALLATION OF OG INSTEAD THIS LOCAL 
# DISTRIBUTION, SET THE FOLLOWING TO true.

test_against_installation = false


#--------------------------------------------------------------
# DO NOT CHANGE ANYTHING BELOW THIS LINE

unless test_against_installation
  $:.unshift File.expand_path( File.join( File.dirname(__FILE__), '..', '..', 'lib' ) )
end

$DBG = debug

og_mysql = {
  :destroy => true,
  :store => :mysql,
  :user => 'root',
  :name => 'test',
# :password => 'navelrulez',
# :socket => '/var/run/mysqld/mysqld.sock'
}

og_psql = {
  :destroy => true,
  :store => :psql,
  :user => 'postgres',
  :password => 'postgres',
  :name => 'test'
}

og_sqlite = {
  :destroy => true,
  :store => :sqlite,
  :name => 'test'
}

og_kirby = {
  :destroy => true,
  :store => :kirby,
  :name => 'test',
  :embedded => true
}

og_memory = {
  :store => :memory,
  :name => :test,
  :destroy => true
}  

# This sets the common global vars to be used by the tests.

eval %{
  @og_config1 = og_config = og_#{configA}
  @og_config2 = og_#{configB}
}

require 'stringio'
require 'glue'
require 'glue/logger'
require 'og'

Logger.set(Logger.new(StringIO.new)) unless $DBG

Og.thread_safe = false

$og1 ||= Og.setup(@og_config1)
$og2 ||= Og.setup(@og_config2)

# * Tom Sawyer <transfire@gmail.com>
# * George Moschovitis <gm@navel.gr>

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
og-0.29.0 test/og/CONFIG.rb
og-0.28.0 test/og/CONFIG.rb