From cfa82f4426535dd2e0e27ae2757eafbcf27a26d6 Mon Sep 17 00:00:00 2001 From: Dan Howe Date: Mon, 10 Sep 2018 07:35:17 +1000 Subject: [PATCH] Add tests --- tests/__init__.py | 0 tests/froude_test.py | 11 +++++++++++ 2 files changed, 11 insertions(+) create mode 100644 tests/__init__.py create mode 100644 tests/froude_test.py diff --git a/tests/__init__.py b/tests/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/tests/froude_test.py b/tests/froude_test.py new file mode 100644 index 0000000..5b36462 --- /dev/null +++ b/tests/froude_test.py @@ -0,0 +1,11 @@ +import pytest +from scaling import froude + +def test_unit_to_same_unit(): + assert froude.model_to_proto(1, 1, 'm', 'm') == 1 + +def test_froude_length(): + assert froude.model_to_proto(1, 10, 'm', 'm') == 10 + +def test_froude_force(): + assert froude.model_to_proto(1, 10, 'N', 'N') == 1000