forked from nathanwoodburn/firewalletbrowser
feat: Add some inital tests
This commit is contained in:
@@ -32,10 +32,4 @@ jobs:
|
|||||||
- name: Run tests
|
- name: Run tests
|
||||||
run: |
|
run: |
|
||||||
echo "Testing with Python ${{ matrix.python-version }}"
|
echo "Testing with Python ${{ matrix.python-version }}"
|
||||||
python -m pytest main.py
|
python -m pytest main.py
|
||||||
|
|
||||||
- name: Check compatibility
|
|
||||||
run: |
|
|
||||||
# Add any additional compatibility checks if needed
|
|
||||||
python --version
|
|
||||||
python -c "import sys; print(f'Python {sys.version_info.major}.{sys.version_info.minor} compatibility test passed')"
|
|
||||||
6
main.py
6
main.py
@@ -1906,3 +1906,9 @@ if __name__ == '__main__':
|
|||||||
app.run(debug=True)
|
app.run(debug=True)
|
||||||
else:
|
else:
|
||||||
app.run()
|
app.run()
|
||||||
|
|
||||||
|
def tests():
|
||||||
|
assert blocks_to_time(6) == "1 hrs"
|
||||||
|
assert blocks_to_time(3) == "30 mins"
|
||||||
|
assert blocks_to_time(1) == "10 mins"
|
||||||
|
assert blocks_to_time(10) == "1 hrs 40 mins"
|
||||||
Reference in New Issue
Block a user