Sha256: 5f100870de3e5e2f23f1c93ec879aa705bd8ee53f1ca152bca8733f2ac3c93fb

Contents?: true

Size: 839 Bytes

Versions: 1

Compression:

Stored size: 839 Bytes

Contents

require 'test/unit'
require 'rscm'
require 'rscm/generic_scm_tests'

module RSCM
  class P4Client 
      
      include Test::Unit::Assertions
      
      def p4(cmd)
          assert_equal @expected, cmd
          @returnValue
      end
      
      def expect cmd, returnValue
          @expected = cmd
          @returnValue = returnValue
      end
  end

  class P4ClientTests < Test::Unit::TestCase
      def test_correctly_decodes_changes_specifiers
          client = P4Client.new "foo"
          client.expect "changes //...@1200,2036/01/01:00:00:00", ""
          client.revisions("1200", Time.infinity) 
      end
      def test_should_accept_changespecs_for_from_and_to
          client = P4Client.new "foo"
          client.expect "changes //...@1200,@1300", ""
          client.revisions("1200", "1300") 
      end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
rscm-0.3.0 test/rscm/scm/p4client_test.rb