kfdtest: Instantiate Assembler in KFDBaseComponentTest
Instantiate in KFDBaseComponentTest::SetUp() and destroy in TearDown(). This ensures m_pAsm is available for all tests. Signed-off-by: Graham Sider <Graham.Sider@amd.com> Change-Id: I8b98a5350a9739d71455f14552c9879bdb1c475d
This commit is contained in:
committed by
Harish Kasiviswanathan
parent
2f73db8fb0
commit
235636d598
@@ -68,6 +68,8 @@ void KFDBaseComponentTest::SetUp() {
|
||||
|
||||
g_baseTest = this;
|
||||
|
||||
m_pAsm = new Assembler(GetGfxVersion(nodeProperties));
|
||||
|
||||
ROUTINE_END
|
||||
}
|
||||
|
||||
@@ -86,6 +88,10 @@ void KFDBaseComponentTest::TearDown() {
|
||||
EXPECT_SUCCESS(hsaKmtCloseKFD());
|
||||
g_baseTest = NULL;
|
||||
|
||||
if (m_pAsm)
|
||||
delete m_pAsm;
|
||||
m_pAsm = nullptr;
|
||||
|
||||
ROUTINE_END
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user