scons,tests: Delete support for the UnitTest scons class/function.

There are no more UnitTest()s, and we shouldn't write any new ones.
Delete the function-like class used to set them up.

Change-Id: Ia353cf698c907b5c7f7c383495f611089fa8b019
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/45168
Reviewed-by: Daniel Carvalho <odanrc@yahoo.com.br>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Giacomo Travaglini <giacomo.travaglini@arm.com>
Tested-by: kokoro <noreply+kokoro@google.com>
This commit is contained in:
Gabe Black
2021-05-06 21:08:15 -07:00
parent b8f90fd5e0
commit 0899f4135e

View File

@@ -589,22 +589,6 @@ class Executable(object, metaclass=ExecutableMeta):
else:
return env.Program(self.path(env), objs)
class UnitTest(Executable):
'''Create a UnitTest'''
def __init__(self, target, *srcs_and_filts, **kwargs):
super(UnitTest, self).__init__(target, *srcs_and_filts)
self.main = kwargs.get('main', False)
def declare(self, env):
sources = list(self.sources)
for f in self.filters:
sources += Source.all.apply_filter(env, f)
objs = self.srcs_to_objs(env, sources) + env['STATIC_OBJS']
if self.main:
objs += env['MAIN_OBJS']
return super(UnitTest, self).declare(env, objs)
class GTest(Executable):
'''Create a unit test based on the google test framework.'''
all = []
@@ -660,7 +644,6 @@ Export('SimObject')
Export('ProtoBuf')
Export('GrpcProtoBuf')
Export('Executable')
Export('UnitTest')
Export('GTest')
########################################################################