in reply to use_ok with version number

I think you just need to put a comma between module name and version:

use_ok 'Acme::Stuff', '1.1.2';

(Unlike the regular use statement, use_ok is a subroutine call with arguments)

Replies are listed 'Best First'.
Re^2: use_ok with version number
by happy.barney (Friar) on Nov 26, 2009 at 11:19 UTC
    regardless of comma, use_ok has a regex in code, that allows max one dot in version string. Also vstring is not supported by use_ok.

      Wow, this is good to know.

      I just tested your assertion, and it looks like you're right. When the actual version is '1.1.2', specifying version '2' fails as it should, but specifying version '1.1.3' succeeds.

      I suppose I ought to report this as a bug in Test::More.

        it already is, as number 55 :-)