The simplest way to write a test case is to redefine the behavior of the MAIN sequence by overriding the body() TCM. This is sufficient to create the test case, because the MAIN sequence is started automatically.
extend MAIN usb_sequence_s {
body()@driver.clock is only {
do usb_transaction_s keeping {
.pid == SETUP};
}; // End of do
}; // End of body()
}; // End of MAIN
To create a simple test based on the sequence library is to choose a subset that will be activated in the specific test and then set the weights for each kind using keep soft select.
extend MAIN usb_sequence_s {
body()@driver.clock is only {
do usb_transaction_s keeping {
.pid == SETUP};
}; // End of do
}; // End of body()
}; // End of MAIN
To create a simple test based on the sequence library is to choose a subset that will be activated in the specific test and then set the weights for each kind using keep soft select.