Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class our_test extends uvm_test; //our_test is child of class of uvm_test
- `uvm_component_utils(our_test) //this will register our class with the factory
- //instantiate classes
- our_env env; //initiated the env class we created
- //constructor
- //build phase
- function void build_phase(uvm_phase phase);
- env = our_env :: type_id :: create("env", this); //this is we created a new object
- endfunction
- //constructor- (a function to create class and initialize class properties)
- function new (string name = "our_test", uvm_component parent = null);
- super.new(name, parent); //refers to the properties of the parent class(default UVM test class)
- endfunction
- //build phase
- function void build_phase(uvm_phase phase);
- //build other components
- endfunction
- //connect phase
- function void connect_phase(uvm_phase phase);
- //necessary connections
- endfunction
- //runphase
- task run_phase(uvm_phase phase);
- //main logic
- endtask
- endclass
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement