From 83fc5764422b6ea700223333a79dd180b21911a8 Mon Sep 17 00:00:00 2001
From: Frederik Hennig <frederik.hennig@fau.de>
Date: Thu, 28 Mar 2024 15:41:15 +0100
Subject: [PATCH] extend typification tests to check type of each expression

---
 tests/nbackend/kernelcreation/test_typification.py | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/tests/nbackend/kernelcreation/test_typification.py b/tests/nbackend/kernelcreation/test_typification.py
index fc139c714..ef746c614 100644
--- a/tests/nbackend/kernelcreation/test_typification.py
+++ b/tests/nbackend/kernelcreation/test_typification.py
@@ -38,6 +38,7 @@ def test_typify_simple():
     assert isinstance(fasm, PsDeclaration)
 
     def check(expr):
+        assert expr.dtype == ctx.default_dtype
         match expr:
             case PsConstantExpr(cs):
                 assert cs.value == 2
@@ -86,6 +87,7 @@ def test_contextual_typing():
     expr = typify(expr)
 
     def check(expr):
+        assert expr.dtype == ctx.default_dtype
         match expr:
             case PsConstantExpr(cs):
                 assert cs.value in (2, 3, -4)
-- 
GitLab