Skip to content

Commit

Permalink
1.108.1
Browse files Browse the repository at this point in the history
See release notes.
  • Loading branch information
cjdsellers authored Mar 9, 2021
2 parents 33786f5 + 6df31f6 commit 4a1e5e5
Show file tree
Hide file tree
Showing 10 changed files with 562 additions and 552 deletions.
7 changes: 6 additions & 1 deletion .github/workflows/test-tag-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -114,9 +114,14 @@ jobs:
- name: Set output
id: vars
run: |
release = sed -n '/^#/,${p;/^---/q}' RELEASES.md
release="${release//'%'/'%25'}"
release="${release//$'\n'/'%0A'}"
release="${release//$'\r'/'%0D'}"
echo $release
echo "::set-output name=tag_name::v$(poetry version --short)"
echo "::set-output name=release_name::NautilusTrader $(poetry version --short) Beta"
echo "::set-output name=body::$(sed -n '/^#/,${p;/^---/q}' RELEASES.md)"
echo "::set-output name=body::$release"
# Create GitHub release
- name: Create release
Expand Down
2 changes: 1 addition & 1 deletion RELEASES.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# NautilusTrader 1.108.0 Beta - Release Notes
# NautilusTrader 1.108.1 Beta - Release Notes

This release executes a major refactoring of `Symbol` and how securities are
generally identified within the platform. This will allow a smoother integration
Expand Down
20 changes: 10 additions & 10 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ build-backend = "poetry.core.masonry.api"

[tool.poetry]
name = "nautilus_trader"
version = "1.108.0"
version = "1.108.1"
description = "A high-performance algorithmic trading platform and event-driven backtester"
authors = ["Nautech Systems <[email protected]>"]
license = "LGPL-3.0-or-later"
Expand Down Expand Up @@ -33,7 +33,7 @@ generate-setup-file = false

[tool.poetry.dependencies]
python = "^3.7.9"
ccxt = "^1.42.66"
ccxt = "^1.42.67"
cython = "^3.0a6"
empyrical = "^0.5.5"
ib_insync = "^0.9.65"
Expand Down Expand Up @@ -61,7 +61,7 @@ flake8 = "^3.8.4"
isort = "^5.7.0"
nox = "^2020.12.31"
parameterized = "^0.8.1"
pre-commit = "^2.11.0"
pre-commit = "2.10.0"
pytest = "^6.2.2"
pytest-cov = "^2.10.1"
pytest-xdist = { version = "^2.2.0", extras = ["psutil"] }
Expand Down
32 changes: 19 additions & 13 deletions tests/unit_tests/core/test_core_correctness.py
Original file line number Diff line number Diff line change
Expand Up @@ -130,24 +130,27 @@ def test_callable_or_none_when_arg_not_callable_raises_type_error(self):
with pytest.raises(TypeError):
PyCondition.callable_or_none("not_callable", "param")

def test_callable_or_none_when_arg_is_callable_or_none_does_nothing(self):
@pytest.mark.parametrize(
"value",
[[].append, None],
)
def test_callable_or_none_when_arg_is_callable_or_none_does_nothing(self, value):
# Arrange
collection = []

# Act
# Assert: ValueError not raised
PyCondition.callable_or_none(collection.append, "param")
PyCondition.callable_or_none(None, "param")
PyCondition.callable_or_none(value, "param")

def test_equal_when_args_not_equal_raises_value_error(self):
@pytest.mark.parametrize(
"id1, id2",
[["O-123456", "O-123"],
["O-123456", "P-123456"]],
)
def test_equal_when_args_not_equal_raises_value_error(self, id1, id2):
# Arrange
# Act
# Assert
with pytest.raises(ValueError):
PyCondition.equal("O-123456", "O-123", "order_id1", "order_id2")

with pytest.raises(ValueError):
PyCondition.equal("O-123456", "P-123456", "order_id", "position_id")
PyCondition.equal(id1, id2, "id1", "id2")

def test_equal_when_args_are_equal_does_nothing(self):
# Arrange
Expand Down Expand Up @@ -197,12 +200,15 @@ def test_dict_types_when_contains_incorrect_types_raises_type_error(self, value)
with pytest.raises(TypeError):
PyCondition.dict_types(value, str, str, "param")

def test_dict_types_when_contains_correct_types_or_none_does_nothing(self):
@pytest.mark.parametrize(
"value",
[{"key": 1}, {}],
)
def test_dict_types_when_contains_correct_types_or_none_does_nothing(self, value):
# Arrange
# Act
# Assert: ValueError not raised
PyCondition.dict_types({"key": 1}, str, int, "param_name")
PyCondition.dict_types({}, str, str, "param_name")
PyCondition.dict_types(value, str, int, "param_name")

def test_is_in_when_item_not_in_list_raises_type_error(self):
# Arrange
Expand Down
Loading

0 comments on commit 4a1e5e5

Please sign in to comment.