Align test directory with working directory

This commit is contained in:
Matthias
2024-07-13 10:10:12 +02:00
parent 50dcd04816
commit 8a166b04f9
8 changed files with 0 additions and 0 deletions

View File

@@ -0,0 +1,20 @@
import pytest
from freqtrade.util import render_template, render_template_with_fallback
def test_render_template_fallback():
from jinja2.exceptions import TemplateNotFound
with pytest.raises(TemplateNotFound):
val = render_template(
templatefile="subtemplates/indicators_does-not-exist.j2",
arguments={},
)
val = render_template_with_fallback(
templatefile="strategy_subtemplates/indicators_does-not-exist.j2",
templatefallbackfile="strategy_subtemplates/indicators_minimal.j2",
)
assert isinstance(val, str)
assert "if self.dp" in val