aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/test_alphanum.py16
1 files changed, 16 insertions, 0 deletions
diff --git a/tests/test_alphanum.py b/tests/test_alphanum.py
index fc9bc41..d567bdb 100644
--- a/tests/test_alphanum.py
+++ b/tests/test_alphanum.py
@@ -15,3 +15,19 @@ def test_subsequent_strings_differ():
foo = alphanum.generate(10)
bar = alphanum.generate(10)
assert foo != bar
+
+
+def test_secure_no_string_length():
+ foo = alphanum.generate_s()
+ assert len(foo) == 1
+
+
+def test_secure_with_string_length():
+ foo = alphanum.generate_s(10)
+ assert len(foo) == 10
+
+
+def test_secure_subsequent_strings_differ():
+ foo = alphanum.generate_s(10)
+ bar = alphanum.generate_s(10)
+ assert foo != bar