-
Notifications
You must be signed in to change notification settings - Fork 137
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Python: export `dna_jellyfish.__version__` * Perl: export `$jellyfish::VERSION` * Ruby: export `Jellyfish::VERSION`
- Loading branch information
Showing
7 changed files
with
83 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# This file is part of Jellyfish. | ||
# | ||
# This work is dual-licensed under 3-Clause BSD License or GPL 3.0. | ||
# You can choose between one of them if you use this work. | ||
# | ||
# `SPDX-License-Identifier: BSD-3-Clause OR GPL-3.0` | ||
|
||
use strict; | ||
use warnings; | ||
use Test::More; | ||
|
||
require_ok('jellyfish'); | ||
|
||
# Test version | ||
{ | ||
my $version = $jellyfish::VERSION; | ||
my $m = $version =~ m/^(\d+)\.(\d+)\.(\d+)$/; | ||
ok($m, , "Version match regexp"); | ||
ok($1 > 0, "Major positive"); | ||
ok($2 >= 0, "Minor"); | ||
ok($3 >= 0, "Revision"); | ||
} | ||
|
||
done_testing; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
# This file is part of Jellyfish. | ||
# | ||
# This work is dual-licensed under 3-Clause BSD License or GPL 3.0. | ||
# You can choose between one of them if you use this work. | ||
# | ||
# `SPDX-License-Identifier: BSD-3-Clause OR GPL-3.0` | ||
|
||
import unittest | ||
import sys | ||
import re | ||
|
||
import dna_jellyfish as jf | ||
|
||
class TestMerFile(unittest.TestCase): | ||
def test_version(self): | ||
version = jf.__version__ | ||
m = re.match('^(\d+)\.(\d+).(\d+)$', version) | ||
self.assertIsNotNone(m) | ||
self.assertGreater(int(m[1]), 0) | ||
self.assertGreaterEqual(int(m[2]), 0) | ||
self.assertGreaterEqual(int(m[3]), 0) | ||
|
||
if __name__ == '__main__': | ||
data = sys.argv.pop(1) | ||
unittest.main() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
# This file is part of Jellyfish. | ||
# | ||
# This work is dual-licensed under 3-Clause BSD License or GPL 3.0. | ||
# You can choose between one of them if you use this work. | ||
# | ||
# `SPDX-License-Identifier: BSD-3-Clause OR GPL-3.0` | ||
|
||
require 'test/unit' | ||
require 'jellyfish' | ||
|
||
|
||
class TestMerFile < Test::Unit::TestCase | ||
def test_version | ||
m = /^(\d+)\.(\d+)\.(\d+)$/ =~ Jellyfish::VERSION | ||
assert_not_nil m | ||
assert_true($1.to_i > 0) | ||
assert_true($2.to_i >= 0) | ||
assert_true($3.to_i >= 0) | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters