From 67bfdaf57ff0537a66b419128c15691dd7abb83a Mon Sep 17 00:00:00 2001
From: John Tourtellott <john.tourtellott@kitware.com>
Date: Tue, 3 May 2022 16:51:55 -0400
Subject: [PATCH] Change dictionary key from smtk model EntityRef to Entity

EntityRef is not hashable
---
 smtk/simulation/testing/python/test_tagging.py | 11 +++++------
 1 file changed, 5 insertions(+), 6 deletions(-)

diff --git a/smtk/simulation/testing/python/test_tagging.py b/smtk/simulation/testing/python/test_tagging.py
index 0e682a4..bcdbbdc 100644
--- a/smtk/simulation/testing/python/test_tagging.py
+++ b/smtk/simulation/testing/python/test_tagging.py
@@ -12,7 +12,6 @@ import unittest
 
 import smtksimulationadh
 
-
 mesh_filename = "scenario.h5m"
 att_filename  = "CTBV3_scenario.sbi"
 
@@ -88,12 +87,12 @@ class Tagging(smtk.testing.TestCase):
 
         z_mids = {}
         for soil_face in soil_faces:
-            z_mids[soil_face] = z_mid(soil_face)
+            z_mids[soil_face.entity()] = z_mid(soil_face)
 
         for soil_face in soil_faces:
-            if z_mids[soil_face] < z_mids[soil_bottom_face]:
+            if z_mids[soil_face.entity()] < z_mids[soil_bottom_face.entity()]:
                 soil_bottom_face = soil_face
-            if z_mids[soil_face] > z_mids[soil_top_face]:
+            if z_mids[soil_face.entity()] > z_mids[soil_top_face.entity()]:
                 soil_top_face = soil_face
 
         # construct a group for the bottom soil face
@@ -118,10 +117,10 @@ class Tagging(smtk.testing.TestCase):
         target_top_face = target_faces[0]
         z_mids = {}
         for target_face in target_faces:
-            z_mids[target_face] = z_mid(target_face)
+            z_mids[target_face.entity()] = z_mid(target_face)
 
         for target_face in target_faces:
-            if z_mids[target_face] > z_mids[target_top_face]:
+            if z_mids[target_face.entity()] > z_mids[target_top_face.entity()]:
                 target_top_face = target_face
 
         # construct a group for the top target face
-- 
GitLab