@davoodmehraban89 / Aram / commits / 2ca220d
Fork 0

test(desktop): inspect exact figures in native Tk tab and verify clearing

davoodmehraban89 committed Oct 31, 2026 at 20:26 UTC 2ca220d0c8ca321be9c34825df4fa632b59108ec
1 file changed +8
backend/tests/test_desktop_five_statement.py
+8
@@ -218,8 +218,16 @@ def test_native_window_shows_real_successful_five_statement_result(tmp_path):
218 window.outcome_tree.item(row, "values")[1] == "قابل بررسی"
219 for row in rows
220 )
221 + amounts = [
222 + window.figures_tree.item(row, "values")
223 + for row in window.figures_tree.get_children()
224 + ]
225 + assert len(amounts) == 28
226 + assert ("ترازنامه", "دارایی‌ها", "100", "پیش‌نویس قابل بررسی؛ غیررسمی") in amounts
227 + assert ("سود و زیان", "سود خالص", "20", "پیش‌نویس قابل بررسی؛ غیررسمی") in amounts
228 window.clear_button.invoke()
229 assert not window.outcome_tree.get_children()
230 + assert not window.figures_tree.get_children()
231 assert window.controller.result is None
232 assert str(window.run_button.cget("state")) == "disabled"
233 finally: