Sha256: 70a481b02ef01a969c9e93711407615339db4bae11028654203e66e4657bf6dc

Contents?: true

Size: 655 Bytes

Versions: 1

Compression:

Stored size: 655 Bytes

Contents

require File.expand_path(__FILE__).sub(%r(/test/.*), '/test/test_helper.rb')
require File.expand_path(__FILE__).sub(%r(.*/test/), '').sub(/test_(.*)\.rb/,'\1')

class TestKnowlegeBase < Test::Unit::TestCase
  def test_no_namespace
    TmpFile.with_dir do |dir|
      kb = KnowledgeBase.new dir
      assert_nil kb.namespace
      kb.save

      kb = KnowledgeBase.load dir
      assert_nil kb.namespace
    end
  end

  def test_namespace
    TmpFile.with_dir do |dir|
      kb = KnowledgeBase.new dir, "Hsa"
      assert_equal "Hsa", kb.namespace
      kb.save

      kb = KnowledgeBase.load dir
      assert_equal "Hsa", kb.namespace
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
scout-gear-10.7.3 test/scout/test_knowledge_base.rb