#26 utPLSQL.test should not check for existence of proc/func/obj

Closed-Fixed
nobody
utPLSQL (6)
5
2013-10-12
2004-08-20
No

In 2.1.1 if passing <program> to utPLSQL.test or
utPLSQL.run to run all tests from a package named
<prefix><program>, it checks, that <program> really
exists (by calling utPLSQL.progexists from utPLSQL.test).

IMHO this is a conceptual error:

each test contains unique setup/teardown procedures,
which can be different for different tests _of the same
program_.

I.e. there is usually one test package for each
setup/teardown environment, but multiple packages for
each procedure/package.

Quick Fix: Make utPLSQL.progexists always return TRUE.

Best regards,

Jens

Discussion

  • Chris Rimmer

    Chris Rimmer - 2004-08-24

    Logged In: YES
    user_id=353735

    Jens,

    Thanks for commenting on this. When utPLSQL was first
    written, it differed from JUnit etc in that when running it
    (using utplsql.test), you passed the name of the package to
    test, rather than the name of the package doing the testing.
    This then assumed that <package> would have a single test
    package named <prefix><package>.

    This turned out to be too restrictive, so Steven wrote
    utplsql.run, to which you pass the name of the test package.
    This package can have any name you like and I don't believe
    that utplsql.progexists gets called in this case. So I
    suggest you use utplsql.run.

    Let me know if I have misunderstood your problem.

    Chris

     
  • Chris Rimmer

    Chris Rimmer - 2004-08-24
    • status: open --> closed
     
  • Jens Scheidtmann

    Logged In: YES
    user_id=167229

    Dear Chris,

    well "run" calls "test" in my installation (V2.1.1). So both
    utPLSQL.run('<prefix><package>') and
    utPLSQL.test('<package>') complain that 'Program named
    "<package>" does not exists'.

    Jens

     
  • Chris Rimmer

    Chris Rimmer - 2004-08-25

    Logged In: YES
    user_id=353735

    Jens,

    Are you sure? When I call utplsql.test('XXXXX') I get
    'Program named "XXXXX" does not exist', but
    utplsql.run('UT_XXXXX') gives 'Program named "UT_XXXXX" does
    not exist'. In the second case, progexists is looking for
    the test package, not the tested package, so if that doesn't
    exist, you've got problems!

    Chris

     
  • Paul Walker

    Paul Walker - 2013-10-12
    • Status: closed --> Closed-Fixed
     

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks