Sha256: def773313c702cac751e8fbc60124a33aa20743708573a16be92aef9b4cf97cb

Contents?: true

Size: 885 Bytes

Versions: 3

Compression:

Stored size: 885 Bytes

Contents

# Copyright: Copyright 2009 Topic Maps Lab, University of Leipzig.
# License:   Apache License, Version 2.0

$LOAD_PATH.unshift File.join(File.dirname(__FILE__), "/../lib")

require 'spec'
require 'rtm'

def implementation_for_spec
  engine = ENV['RTM_IMPLEMENTATION'] && ENV['RTM_IMPLEMENTATION'].to_sym || :ontopia # if env is nil, the "normal progress will go on" # TODO: remove ontopia, as it should be chosen by connect by default
end
def get_used_tm_sys
  RTM.connect(:implementation => implementation_for_spec)
end

def get_used_tm_sys_tm
  @basis = get_used_tm_sys
  tm = @basis.create("http://www.topicmapslab.de/")
  if (implementation_for_spec == :hatana)
    tm.merge_in(RTM.connect(:implementation => :ontopia).create("http://www.topicmapslab.de/"))
  end
# tm.enable_query_cache
  return tm
end

def ar_available?
  !Gem.source_index.find_name('activerecord').empty?
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
rtm-0.3.0 spec/spec_helper.rb
rtm-0.2.1 spec/spec_helper.rb
rtm-0.2 spec/spec_helper.rb