Sha256: 957f581f6cb1949a5956c3b001ae96c34b7defaa02cf492f89590f2e5a23c2ee

Contents?: true

Size: 787 Bytes

Versions: 12

Compression:

Stored size: 787 Bytes

Contents

require 'test_helper'

setup_database()

require 'build-tool/model/feature'

class FeatureTest < ActiveSupport::TestCase

    test 'Constructor' do
        feat = BuildTool::Feature.new
    end

    test 'Active logic' do
        feat = BuildTool::Feature.new
        assert( feat.default_active?, 'By default all features are active' )
        assert( feat.active?, 'By default all features are active' )
        feat.default_active = false
        assert( !feat.default_active? )
        assert( !feat.active?, 'By default active? uses default_active?' )
        feat.active = true
        assert( !feat.default_active? )
        assert( feat.active? )
        feat.active = nil
        assert( !feat.default_active? )
        assert( !feat.active? )
    end

end # class FeatureTest

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
build-tool-0.6.9 test/unit/model/feature_test.rb
build-tool-0.6.8 test/unit/model/feature_test.rb
build-tool-0.6.7 test/unit/model/feature_test.rb
build-tool-0.6.6 test/unit/model/feature_test.rb
build-tool-0.6.5 test/unit/model/feature_test.rb
build-tool-0.6.4 test/unit/model/feature_test.rb
build-tool-0.6.3 test/unit/model/feature_test.rb
build-tool-0.6.2 test/unit/model/feature_test.rb
build-tool-0.6.1 test/unit/model/feature_test.rb
build-tool-0.6.0 test/unit/model/feature_test.rb
build-tool-0.6.0.rc2 test/unit/model/feature_test.rb
build-tool-0.6.0.rc1 test/unit/model/feature_test.rb