test: cover tuple factor rule conditions
This commit is contained in:
parent
5a4657781f
commit
92d3168f27
|
|
@ -309,6 +309,15 @@ class FactorRulesPathTests(unittest.TestCase):
|
||||||
|
|
||||||
self.assertIn("- Conditions: {'threshold': 5}", summary)
|
self.assertIn("- Conditions: {'threshold': 5}", summary)
|
||||||
|
|
||||||
|
def test_summarize_factor_rules_stringifies_tuple_conditions(self):
|
||||||
|
summary = summarize_factor_rules(
|
||||||
|
[{"name": "Carry", "signal": "neutral", "conditions": [("threshold", 5)]}],
|
||||||
|
ticker="LQD",
|
||||||
|
trade_date="2026-03-07",
|
||||||
|
)
|
||||||
|
|
||||||
|
self.assertIn("- Conditions: ('threshold', 5)", summary)
|
||||||
|
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
unittest.main()
|
unittest.main()
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue