# \#UVM-uvm\_test

**URL:** https://verificationacademy.com/forums/tag/uvm-uvm-test/4836.md

[Latest](https://verificationacademy.com/forums/latest.md) · [Categories](https://verificationacademy.com/forums/categories.md) · [Tags](https://verificationacademy.com/forums/tags.md)

---

## [UVM\_TEST](https://verificationacademy.com/forums/t/uvm-test/39538)

<div class="topic-metadata">

**Author:** [@J\_Y\_B](https://verificationacademy.com/forums/u/J_Y_B)\
**Replies:** 1\
**Last updated:** [September 7, 2021, 6:23pm UTC](https://verificationacademy.com/forums/t/uvm-test/39538 "2021-09-07T18:23:17Z")

</div>

Can I use the test case deriving from uvm\_driver or other component instead of uvm\_test? Are there any potential risks?

---

## [Constraints for a random variable in uvm test cases](https://verificationacademy.com/forums/t/constraints-for-a-random-variable-in-uvm-test-cases/35757)

<div class="topic-metadata">

**Author:** [@srikanth.verification](https://verificationacademy.com/forums/u/srikanth.verification)\
**Replies:** 3\
**Last updated:** [September 16, 2020, 10:44am UTC](https://verificationacademy.com/forums/t/constraints-for-a-random-variable-in-uvm-test-cases/35757 "2020-09-16T10:44:57Z")

</div>

Hi I am writing uvm test cases as part of my project. My question is Can we write Constraints for a variable declared as “rand” in uvm test cases? I haven’t use constraints in test cases before. Please reply. Regar…

---

## [Use \`uvm\_do macro from uvm\_test](https://verificationacademy.com/forums/t/use-uvm-do-macro-from-uvm-test/36287)

<div class="topic-metadata">

**Author:** [@DamianS](https://verificationacademy.com/forums/u/DamianS)\
**Replies:** 9\
**Last updated:** [July 24, 2019, 12:01pm UTC](https://verificationacademy.com/forums/t/use-uvm-do-macro-from-uvm-test/36287 "2019-07-24T12:01:49Z")

</div>

Hi, I know there’s good advice against using uvm\_do macros but it saves so much writing, 1 line instead of a page: create, randomize, start, finish… I use it in sequences without a problem. However when using it in a …

---

## [UVM run tests without using the run\_test(test\_name) method](https://verificationacademy.com/forums/t/uvm-run-tests-without-using-the-run-test-test-name-method/34835)

<div class="topic-metadata">

**Author:** [@JaafarHassan](https://verificationacademy.com/forums/u/JaafarHassan)\
**Replies:** 11\
**Last updated:** [August 12, 2018, 6:16am UTC](https://verificationacademy.com/forums/t/uvm-run-tests-without-using-the-run-test-test-name-method/34835 "2018-08-12T06:16:00Z")

</div>

In my uvm project, I need to instantiate the test before run it. because I need to pass an array of requests to this test. so, the run\_test(test\_name); doesn’t work for me. because I don’t pass the the requests array th…

---

## [Can I pass variable from uvm\_sequence to test class?](https://verificationacademy.com/forums/t/can-i-pass-variable-from-uvm-sequence-to-test-class/34112)

<div class="topic-metadata">

**Author:** [@peterjin](https://verificationacademy.com/forums/u/peterjin)\
**Replies:** 2\
**Last updated:** [February 22, 2018, 2:34am UTC](https://verificationacademy.com/forums/t/can-i-pass-variable-from-uvm-sequence-to-test-class/34112 "2018-02-22T02:34:05Z")

</div>

I have a uvm\_sequence that generates packets and this packet has an error bit. This sequence will also randomly set the error bit field when generating the packet. Besides, there is a counter in this sequence that counts…

---

## [Access testbench top signal in test or sequence](https://verificationacademy.com/forums/t/access-testbench-top-signal-in-test-or-sequence/33279)

<div class="topic-metadata">

**Author:** [@rakesh2learn](https://verificationacademy.com/forums/u/rakesh2learn)\
**Replies:** 1\
**Last updated:** [July 6, 2017, 7:55pm UTC](https://verificationacademy.com/forums/t/access-testbench-top-signal-in-test-or-sequence/33279 "2017-07-06T19:55:48Z")

</div>

Hi, I want to access the reset signal from testbench top level in test or sequence. In testbench I have the reset signal declared as module top; reg rst; ... initial begin rst = 1'b0; #10; rst = 1'b1; end v\_…

---

## [How to pass a variable from test to sequence?](https://verificationacademy.com/forums/t/how-to-pass-a-variable-from-test-to-sequence/33270)

<div class="topic-metadata">

**Author:** [@rickitura1](https://verificationacademy.com/forums/u/rickitura1)\
**Replies:** 3\
**Last updated:** [July 5, 2017, 11:06am UTC](https://verificationacademy.com/forums/t/how-to-pass-a-variable-from-test-to-sequence/33270 "2017-07-05T11:06:41Z")

</div>

A bit of context, I’m an intern getting to grips with UVM, and this is my first post on this forum, so apologies if my question is poorly asked. I’ve been given a sequence that has hard coded variables, and my aim is to…

---

## [Loop over start and drop\_objection();](https://verificationacademy.com/forums/t/loop-over-start-and-drop-objection/32739)

<div class="topic-metadata">

**Author:** [@saritr](https://verificationacademy.com/forums/u/saritr)\
**Replies:** 1\
**Last updated:** [January 12, 2017, 8:56am UTC](https://verificationacademy.com/forums/t/loop-over-start-and-drop-objection/32739 "2017-01-12T08:56:10Z")

</div>

Is it possible to so something like the following (in the test file): //run\_phase task run\_phase(uvm\_phase phase); tx\_lin\_int\_gt\_sm tx\_seq\_i; axi\_rd\_from\_file\_sequence axi\_seq\_i; phase.raise\_obje…

---

## [Configuration object casting problem in the hierarchical tb](https://verificationacademy.com/forums/t/configuration-object-casting-problem-in-the-hierarchical-tb/31943)

<div class="topic-metadata">

**Author:** [@Vaino](https://verificationacademy.com/forums/u/Vaino)\
**Replies:** 1\
**Last updated:** [June 13, 2016, 9:05pm UTC](https://verificationacademy.com/forums/t/configuration-object-casting-problem-in-the-hierarchical-tb/31943 "2016-06-13T21:05:37Z")

</div>

Hi, I have the following configuration object hierarchy (a-b-c) in which every subclass brings some new additional properties: class cfg\_a extends uvm\_object; endclass : cfg\_a class cfg\_b extends cfg\_a; endclass : cfg\_…

---

## ["uvm\_test": syntax error, unexpected IDENTIFIER and Error in class extension specification](https://verificationacademy.com/forums/t/uvm-test-syntax-error-unexpected-identifier-and-error-in-class-extension-specification/31193)

<div class="topic-metadata">

**Author:** [@Chetanm](https://verificationacademy.com/forums/u/Chetanm)\
**Replies:** 1\
**Last updated:** [November 5, 2015, 8:55pm UTC](https://verificationacademy.com/forums/t/uvm-test-syntax-error-unexpected-identifier-and-error-in-class-extension-specification/31193 "2015-11-05T20:55:01Z")

</div>

Hi, I’m facing a issue with the simple test class (code below) and the error is \*\* Error: env\_test.sv(1): near “uvm\_test”: syntax error, unexpected IDENTIFIER \*\* Error: env\_test.sv(1): Error in class extension specifi…

---

## [How is "test1" instantiated in UVM express example 04?](https://verificationacademy.com/forums/t/how-is-test1-instantiated-in-uvm-express-example-04/29819)

<div class="topic-metadata">

**Author:** [@mike\_bradley63](https://verificationacademy.com/forums/u/mike_bradley63)\
**Replies:** 6\
**Last updated:** [August 15, 2014, 8:45pm UTC](https://verificationacademy.com/forums/t/how-is-test1-instantiated-in-uvm-express-example-04/29819 "2014-08-15T20:45:26Z")

</div>

Hi, I’m looking at the UVM express example 04. In the file tests.sv I see: module tests(); ... import test1\_pkg::\*; // Bring in the test1\_pkg package. initial begin ... run\_test("test1"); end “test1” is a class…
