coreyeng
coreyeng

Reputation: 151

TestNumberer in OrigenTesters?

I see that there is a TestNumberer class in the OrigenTesters at https://github.com/Origen-SDK/origen_testers/blob/master/lib/origen_testers/generator/test_numberer.rb . However, it looks pretty bare, and doesn't look like its being used internally anywhere. So, my question is does this TestNumberer... do anything? I don't see anything in the guides about automatically generating test numbers. What I'd like is something like:

test_numberer.set_base(1000) # for example
test_numberer.set_offset(5)
func (..., test_number: test_numberer.next) #=> test_number = 1000
func (..., test_number: test_numberer.next) #=> test_number = 1005

Possibly even embed incrementing the test number into the func function itself in the interface.

Thanks!

(For the record, I actually already have this in one of my apps for personal use, but am wondering if OrigenTesters already has one, and if not, if it could use one)

Upvotes: 1

Views: 61

Answers (1)

Ginty
Ginty

Reputation: 3501

No, that is old and dead code which should be removed.

There is a solution for generating test numbers though, and that is the TestIds plugin: http://origen-sdk.org/test_ids/

I'm still not totally happy with how it works, but I use it in production today in a large test flow module. I would say it does solve these problems effectively:

  • How do you assign test (and/or bin) numbers within an IP test block, in such a way that it can be included in different SoC test programs which may each want to assign a different range or even a different numbering scheme to the tests for that IP.
  • How do you automatically assign test (and/or bin) numbers in such a way that they will stick and won't change when other tests are added or removed from the flow in future.

I don't really have anything specific that I know is wrong with it, just some niggles that have come up from time to time and it would be good to get other people using it and involved with it to help iron these out.

One of the things that I have come to realize is that it is easier to manage if you explicitly give tests a number (or bin) ID in the test flow like this:

func :blah, number: :blah_test1

func :blah, number: :blah_test2

This makes it easier to control when you want same-named tests to have the same number or not, whilst not locking down to any particular number.

Anyway, you should find the documentation of it pretty good and obviously ask further questions here if you have any.

Upvotes: 1

Related Questions