Permalink
Browse files

version stream test

  • Loading branch information...
1 parent afe9b0b commit 098ba252ac52d8ea7133215f02b9ea290fa6e6b6 @mpapis mpapis committed Aug 3, 2012
Showing with 19 additions and 0 deletions.
  1. +19 −0 core/internal/shell/version/stream/version_stream_comment_test.sh
@@ -0,0 +1,19 @@
+#!/usr/bin/env zsh
+
+source test-sm
+includes internal/version/stream
+
+: simple read/write
+
+[[ -f "${sm_temp_path}/version_stream_1" ]] # status!=0
+echo 10 | __sm.version.stream.write.file "${sm_temp_path}/version_stream_1" # status=0
+
+[[ -f "${sm_temp_path}/version_stream_1" ]] # status=0
+__sm.version.stream.read.file "${sm_temp_path}/version_stream_1" # match=/^10$/
+
+echo 1.1.1 | __sm.version.stream.increase.major # match=/^2.0.0$/
+echo 1.0.0-rc | __sm.version.stream.increase.major # match=/^1.0.0$/
+echo 1.1.1 | __sm.version.stream.increase.minor # match=/^1.2.0$/
+echo 1.1.0-rc | __sm.version.stream.increase.minor # match=/^1.1.0$/
+echo 1.1.1 | __sm.version.stream.increase.tiny # match=/^1.1.2$/
+echo 1.1.1-rc | __sm.version.stream.increase.tiny # match=/^1.1.1$/

0 comments on commit 098ba25

Please sign in to comment.