From d51e381ffc489cc9c984727658475da93d1869dd Mon Sep 17 00:00:00 2001 From: Christoph Date: Thu, 26 Nov 2015 21:41:42 +0100 Subject: make extra sure versioncmp behaves as expected since we depend on versioncmp and that function had some bugs in the past, make sure it behaves as expected in our usecases --- spec/functions/versioncmp_spec.rb | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 spec/functions/versioncmp_spec.rb diff --git a/spec/functions/versioncmp_spec.rb b/spec/functions/versioncmp_spec.rb new file mode 100644 index 0000000..0a24427 --- /dev/null +++ b/spec/functions/versioncmp_spec.rb @@ -0,0 +1,9 @@ +require 'spec_helper' + +describe 'versioncmp' do + it { should run.with_params('7.2','8').and_return(-1) } + it { should run.with_params('7','8').and_return(-1) } + it { should run.with_params('8','8').and_return(0) } + it { should run.with_params('8.1','8').and_return(1) } +end + -- cgit v1.2.3