blob: ae0dac5bfd2304718934b20affff4e6e0c831d32 [file] [log] [blame]
lowRISC Contributors802543a2019-08-31 12:12:56 +01001// Copyright lowRISC contributors.
2// Licensed under the Apache License, Version 2.0, see LICENSE for details.
3// SPDX-License-Identifier: Apache-2.0
4
Srikrishna Iyera8255fd2019-10-11 11:58:17 -07005% if is_cip:
6class ${name}_base_test extends cip_base_test #(
7% else:
lowRISC Contributors802543a2019-08-31 12:12:56 +01008class ${name}_base_test extends dv_base_test #(
Srikrishna Iyera8255fd2019-10-11 11:58:17 -07009% endif
Srikrishna Iyerde3b6732020-01-30 14:50:07 -080010 .CFG_T(${name}_env_cfg),
11 .ENV_T(${name}_env)
lowRISC Contributors802543a2019-08-31 12:12:56 +010012 );
Srikrishna Iyera8255fd2019-10-11 11:58:17 -070013
lowRISC Contributors802543a2019-08-31 12:12:56 +010014 `uvm_component_utils(${name}_base_test)
15 `uvm_component_new
16
17 // the base class dv_base_test creates the following instances:
18 // ${name}_env_cfg: cfg
19 // ${name}_env: env
20
Udi Jonnalagadda3e460cc2020-02-11 15:46:24 -080021% if not has_ral:
22 virtual function void build_phase(uvm_phase phase);
23 super.build_phase(phase);
24 cfg.has_ral = 1'b0;
25 endfunction
Udi Jonnalagadda3e460cc2020-02-11 15:46:24 -080026
Srikrishna Iyerb29ebe82020-05-20 11:29:25 -070027% endif
lowRISC Contributors802543a2019-08-31 12:12:56 +010028 // the base class also looks up UVM_TEST_SEQ plusarg to create and run that seq in
29 // the run_phase; as such, nothing more needs to be done
30
31endclass : ${name}_base_test