0 Replies Latest reply: Jun 20, 2012 3:54 AM by 944750 RSS

    SQL Developer Unit Testing - Validation with PL/SQL

    944750
      Hi,

      I am trying to create Unit tests using SQL Developer UT framework.
      But when i am creating validation using User PL/SQL code option.

      Then how can i check value returned by l_count in code snippet below:

      ----
      -- Please raise an exception if the validation fails.
      -- For example:
      DECLARE
      l_count NUMBER;
      wrong_count EXCEPTION;
      BEGIN
      SELECT count(*) into l_count
      FROM test_recon
      WHERE
      match_num = 99836936
      AND Stg_status_flag <> 'E';

      IF l_count = 0
      THEN
      RAISE wrong_count;
      END IF;

      END;
      ----

      Also, can someone please refer me to few more demo examples (apart from oracle docs) to implement good test cases with SQL developer.

      I appreciate your help.

      Regards
      Dipali