SQL Developer 3 EA1: Unit test

Hi,
I just started using the unit test frame work in SQL Developer 3 EA 1 and I need some help defining a test case involving parent - child tables that are manipulated using a plsql API. The API for the child table requires the key of a record in the parent table. The parent record, and its key, is created by a test case startup process. The key is retrieved using a dynamic value query in the test implementation. It appears the dynamic value query is executed before the test case startup processes have been executed. Is this expected behaviour? My expectation is the startup processes are executed before the dynamic values query.
Also, is it possible to use values from the startup processes as parameter values of the test case other than using a dynamic value query?
Test case summary:
2 Startup processes: The first deletes all data from parent and child tables. The second inserts in a record into the parent table.
Zero Teardown processes.
Test implementation: Dynamic value query that selects the key from the parent table and defines literals for the remaining parameters of the test case.
1 Process validation: Test whether a record has been inserted into the childe table with the expected values.
Thanks
Alistair

Hi Alistair -
We execute the dynamic query to control how many times the test (start up, test case, validation, tear down) cycle executes.
To get the behavior you want, put the test in a test suite and have the test suite start up do the table initialization for you.
Brian Jeffries
SQL Developer Team

Similar Messages

  • Sql developer closes when testing connection

    I have windows 7 64 bit, but, also have ms office 32 bit, so, do need the 32 bit drivers.
    If my path starts with the location of the 32 bit drivers and I test my oracle connection in sql developer with the oci thick driver checked, I get the error stating can't use the 32 bit drivers with a 64 bit machine (Status : Failure -Test failed: C:\app\32BitDrivers\product\11.2.0\client_3\ocijdbc11.dll: Can't load IA 32-bit .dll on a AMD 64-bit platform).
    If the thick driver is unchecked, I get:
    Status : Failure -Test failed: ORA-01017: invalid username/password; logon denied
    I believe this is due to this database being set up to use something like a name validation server(?), because I can connect to another database that does not have that special authentication.
    If I have the path set to the 64 bit driver, sql developer will close when I try to test the connection with either the oci thick driver checked or un-checked (and testing either of the 2 databases).
    any ideas?
    sql developer Version 3.2.20.09
    jdk1.6.0_45 (came in the d/l with sql developer)
    oracle 11gR2
    sqlplus does connect to both databases
    Happen to have toad and was finally able to get it to connect to both databases.
    oh, btw, is the 32 bit driver sqora32.dll?
    what would the 64 bit driver be named?
    thanks,
    Alan
    Edited by: user1219396 on May 10, 2013 9:36 AM

    So, checking what java is running:
    C:\>java -version
    java version "1.7.0_21"
    Java(TM) SE Runtime Environment (build 1.7.0_21-b11)
    Java HotSpot(TM) 64-Bit Server VM (build 23.21-b01, mixed mode)
    However, I have C:\oracle\sqldeveloper\sqldeveloper\bin\sqldeveloper.conf showing
    SetJavaHome C:\oracle\sqldeveloper\jdk1.6.0_45
    Also, I thought that the loading 32 bit on 64 bit system message meant that sql developer was 64 bit. Does it matter is sql dev is 64 or 32 bit and how do I tell which it is?
    Also, there is a log file that shows up in the sql dev bin folder that matches the time when the program closes, like hs_err_pid12380.log. It's showing:
    # A fatal error has been detected by the Java Runtime Environment:
    # EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x000000006d9fd904, pid=13208, tid=8988
    # JRE version: 6.0_45-b06
    # Java VM: Java HotSpot(TM) 64-Bit Server VM (20.45-b01 mixed mode windows-amd64 compressed oops)
    # Problematic frame:
    # V [jvm.dll+0x11d904]
    So, appears that it is using the version specified in the .conf file. However, not seeing useful info in the log file, probably cause there's so much there.
    thanks
    When I try to get it to use the 64 bit driver, sql developer just closes. So, not sure if I'm actually pointing to the right location or what.

  • "Automating" Unit Test Deployment

    We're trying to develop an automated build process using SQL Developer's Unit Test. This works by developing the unit test(s) on database A and then deploying the unit test(s) to database B for the build. Unfortunately, there is an issue when we come to import a new version (v2) of an existing test (v1). If a previous version of the test already exists on database B then the old version is sometimes merged with the new version.
    A simple example would be where:
    (v1) Version 01 has a Startup Process but no Teardown Process
    (v2) Version 02 has a Teardown Process but no Startup Process
    If I import Version 01 then Version 02 I get a test with both a Startup Process and a Teardown Process
    Now, we've managed to manually work around this by using the command - Purge Repository Objects; but this is not ideal as the process is meant to be fully automated.
    Any Ideas...

    Phillip / Brian
    Is it possible to "Purge Repository Objects" through a SQL script instead ?
    From what I can infer from looking at the UT tables the "Purge" truncates all the UT tables except UT_LOOKUP_CATEGORIES and UT_METADATA. Now, I've tried this but it doesn't quite seem to work. I'm missing something here.
    I get the following error message when I try to import files after my manual "purge":
    ORA-01400: cannot insert NULL into ("DCI_UT_REPO"."UT_TEST"."CREATED_ON")
    01400.00000 - "cannot insert NULL into (%s)"
    Regards
    Subboss

  • Unit testing PL/SQL used in APEX application

    question from my customer :
    I am developing an application in Oracle Application Express and am working on unit tests for the PL/SQL stored procedures and packages that are stored in the underlying database and that are used by the APEX application. These unit tests should run within the SQL Developer Unit Test framework.
    The problem is that some of the PL/SQL code stored in the database uses functions like NV('APPLICATION_ITEM') to access items in the apex application. These do not return any values when I try to execute the PL/SQL within the unit test framework, ie through the backend. While it is good that the NV function does not error, NULL do not really work well in my scenario either (for example when the result of this functions is inserted into a NOT NULL column of a table). I can think of a few workarounds, such as creating my own NV function inside the test schema to return desirable values, but nothing seems a really satisfactory solution. I just wonder if there is any best practice recommendation from Oracle for this scenario - how can I run code that uses APEX-specific functions through the back end. I could not find anything in the APEX documentation for this but I'd be interesting to know if there is any recommendation how to best deal with this case.
    I am using SQL Developer version 4.0.0.13.80

    User[[:digit:]*
    Your PL/SQL Package APIs are poorly designed.
    You need to take Tom Kyte's quote to heart:
    "Application come and application go, but data remains forever"
    In short, you need to separate your database processing code (the stuff you need to unit test) from front-end/middle tier code.
    (repetitiveness is for effect.. not rudeness.)
    As such, The PL/SQL code that you need to 'UNIT TEST' must work without needing to run in APEX.
    The PL/SQL code that you need to 'UNIT TEST' must work without needing to run in .NET.
    The PL/SQL code that you need to 'UNIT TEST' must work without needing to run in JSP.
    The PL/SQL code that you need to 'UNIT TEST' must work without needing to run in Jive.
    The PL/SQL code that you need to 'UNIT TEST' must work without needing to run in Ruby.
    The PL/SQL code that you need to 'UNIT TEST' must work without needing to run in Perl::CGI.
    The PL/SQL code that you need to 'UNIT TEST' must work without needing to run in P9.
    The PL/SQL code that you need to 'UNIT TEST' must work without needing to run in <place latest and greatest thing here>.
    Again, I don't mean to sound rude.  I'm just trying to reinforce the idea that you need to separate database code from middle-tier/front-end stuff.
    Basically, you will need to separate all of your packages into multiple parts.
    a _CORE package (that will be unit tested) that does all the hard work
    an _APEX package for APEX infrastructure (this works with NV()/V(), etc.)
    a _NET package for .NET infrastructure when you need it
    a _JSP package for the JSP infrastructure when you need it
    a _JIVE package for the JIVE infrastructure when you need it
    a _<place latest and greatest thing here> for the <place latest and greatest thing here> when you need it.
    MK

  • Suggestions requested for Unit Testing process and build processes.

    Hi All,
    We are using WebLogic WorkShop 8.1 SP2 to build our WebApp. One thing I am trying
    to get together is a "Best Practises" list for aspects of WorkShop developement,
    particularly Unit Testing, Continous Build methodology, source control management
    etc.I have been through the "Best Practises Guide" that comes in WorkShop help,
    but it doesnt address these issues.This could help us all for future projects.
    1)Could anyone give pointers on how to perform Unit Testing using either JUnit/JUnitEE
    in the WorkShop realm, given that Controls cannot be accessed directly from PO
    Test classes.
    2)For a project of size say 5 developers ,does it make sense to have a nightly
    build using tools like CruiseControl?We use CVS for our source control and its
    working out pretty well, but given that we currently have no Unit Tests that can
    be run after the build and that can provide some reports on what broke/what didnt?
    I am sure we all would appreciate any suggestions and more questions on this topic.
    Thanks,
    Vik.

    Hi, Chris,
    can you perhaps explain your solution in greater detail. I am really curious to
    find a way to test controls.
    "Chris Pyrke" <[email protected]> wrote:
    >
    I have written (well it's a bit of a dirty hack really) something that
    lends itself
    to the name ControlTest (it unit tests controls). Its a blend of Junit
    and Cactus
    with some of the source of each brutalised a bit to get things to work
    (not much
    - it was a couple of hours work, when I was supposed to be doing something
    else).
    To write a control test you code something like...
    package com.liffe;
    import com.liffe.controlunit.ControlTestCase;
    import controls.Example;
    public class TestExample extends ControlTestCase
    private Example example = null;
    public void setUp() {
    example = (Example)getControl("example");
    public void testExample() {
    this.assertNotNull(example);
    String result = example.getData();
    assertEquals(result, "Happy as Larry");
    Other tasks required to set up a test are creating a web project with
    a jpf which
    needs some cut and paste code (14 lines) in its begin method and a jsp
    which is
    also cut and paste (5 lines). (ie create a standard web project and paste
    in 2
    pieces of code)
    In the web project you need to create a control (A) with an instance
    name of controlContainer.
    (if it's called something else the pasted in code will need changing
    to reflect)
    In this control you need to put an instance of TestContainerImpl and
    any controls
    that need testing.
    You then need to add a method to the control (A) that looks like…
    * @common:operation
    public String controlTestRun(String theSuiteClassName, boolean xsl)
    container.setControl("example", example);
    return container.controlTestRun(theSuiteClassName, xsl);
    You need to call container.setControl for each control being tested and
    the object
    'container' is the instance name of the TestContainerImpl that was put
    in.
    There are 4 jars (junit, cactus etc) that go in the library. You will
    also need
    the ControlUnitBase project (or maybe just it's jar).
    To use you call a URL like:
    http://localhost:7001/TestWeb/Controller.jpf?test=com.liffe.TestExample
    TestWeb is the name I gave to my web project - this will be different
    for each
    test project
    com.liffe.Example is the class above and will therefore be different
    for each
    test case.
    You can also call
    http://localhost:7001/TestWeb/Controller.jpf?test=com.liffe.TestExample&xsl=true
    (Note the extra &xsl=true) and the browser will (if it can) render it
    more prettily.
    This seems to do the job quite nicely, but there are several caveats
    I would hope
    someone from bea would be able to address before I start using it widely.
    1) To access the control you need to create it (eg as a subcontrol in
    the control
    (A) above.
    To get it into the test case you need to pass it round as an Object (can't
    return
    Control from a control operation). As it's being passed around among
    Java (POJO)
    classes I'm assuming that control remains in the control container context
    so
    this is OK. It seems to work and the Object is some form of proxy as
    any control
    seems to be reproxied before the control is invoked from the test case.
    2) If I'm testing controls called from a JPD then they either need to
    be in a
    control project (and my test cases called from a Web Project) which makes
    for
    a large increase in project numbers (we already have this and are trying
    to resist
    it) To avoid this - as a process project is a brain damaged web project
    I simply
    perform some brain surgery and augment the process project with some
    standard
    files found in any old web project. this means I can call the test JPF
    from a
    browser. This seems nasty, is there a better way?
    3) I would like to be able to deliver without the test code. At the worst
    the
    code can be in place but must be inacessible in a production environment.
    I don't
    know how best to do this - any suggestions (without creating lots of
    projects,
    or lots of manual effort)
    If anyone has read this far I would ask the question does this seem like
    the kind
    of thing that would be useful?
    Hopefully a future version of workshop will have something to enable
    unit testing
    and this hacking will be unnecessary.
    Could someone from BEA tell me if this is a dangerous way to do things?
    Chris
    "vik" <[email protected]> wrote:
    Hi All,
    We are using WebLogic WorkShop 8.1 SP2 to build our WebApp. One thing
    I am trying
    to get together is a "Best Practises" list for aspects of WorkShop developement,
    particularly Unit Testing, Continous Build methodology, source control
    management
    etc.I have been through the "Best Practises Guide" that comes in WorkShop
    help,
    but it doesnt address these issues.This could help us all for future
    projects.
    1)Could anyone give pointers on how to perform Unit Testing using either
    JUnit/JUnitEE
    in the WorkShop realm, given that Controls cannot be accessed directly
    from PO
    Test classes.
    2)For a project of size say 5 developers ,does it make sense to have
    a nightly
    build using tools like CruiseControl?We use CVS for our source control
    and its
    working out pretty well, but given that we currently have no Unit Tests
    that can
    be run after the build and that can provide some reports on what broke/what
    didnt?
    I am sure we all would appreciate any suggestions and more questions
    on this topic.
    Thanks,
    Vik.

  • GeoRaptor 3.2.1 Released for SQL Developer 3.x

    Spatialites!
    After 6 months of development and testing, GeoRaptor 3.2.1 has been released for SQL Developer 3.x (tested on 3.0, 3.1 and 3.2). This release no longer supports SQL Developer 1.x or 2.x releases due to internal changes to the SQL Developer APIs.
    GeoRaptor can be downloaded from the GeoRaptor project's sourceforge page: http://sourceforge.net/projects/georaptor and installed via Help>Check for Updates>Install from Local File. Installation via SQL Developer's update mechanism should be available soon.
    The release notes for this release are:
    * Fixed issues with validate geometry functionality in particular the update dialog box.
    * Revamped "About GeoRaptor" form. Includes clickable URLs, links to mailing lists, version number listing, thanks to testers etc.
    * Placed "About GeoRaptor" icon on GeoRaptor's map toolbar.
    * SQL Developer NLS settings accessed: improvements in the display and entry and numeric data.
      -- Tolerances in Spatial Layer properties will display with the NLS decimal separator eg 0,05.
         Some parts of GeoRaptor such as Validation that show and accept numbers have not been changed from when someone else modified the code.
         If you double click on the left MBR/right MBR icon in the map at the bottom, the current centre position will display according to the NLS settings.
         Editing the value to jump the map to that point works even with grouping separators and decimal separators being commas!
    * Spatial Layer Draw has been modified to use NLS based decimal formatting.
    * New geometry marking/labelling options have been added. In particular you can now label the vertices of a linestring/polygon with the following additional elements:
      -- Cumulative length
      -- Measure (M)
      -- Z value
      -- Labelling of vertices with <id>{X,Y} now also honours 3/4D geometries. If geometry has XYY then it will be labelled as {X,Y,Z} etc.
    * You can also label each vector/segment of a linestring/polygon with:
      -- Length
      -- Cumulative Length
      -- Bearing (approximate for geodetic/geographic data)
      -- Distance (approximate for geodetic/geographic data)
      -- Bearing and Distance (approximate for geodetic/geographic data)
    * The font properties of the mark text can be changed independently of the feature label. This includes the offset and label position (CC, LL, UR etc).
    * New feature labelling options have been provided:
      -- First/middle/last vertex,
      -- Any supplied sdo_point within a line/polygon's sdo_geometry object, or
      -- Calculated by GeoRaptor on the client side using Java Topology Suite.
    * Result sets now have the ability to:
      -- Copy to clipboard all geometries across many rows and columns.
      -- Display one or more (selected) geometries in a popup image window. This functionality is also available in the result set generated by an Identify command.
    * New GeoRaptor Preferences:
      -- Width and height in pixels of the new popup image window (displaying one or more geometry objects) can be set;
      -- Colours of orphan, missing and correct metadata entries for Metadata Manager;
      -- Prefixing with MDSYS for all currently supported spatial objects - sdo_geometry, sdo_point, sdo_elem_info, sdo_ordinates, sdo_dim_info - has been made an option.
      -- There is now a new property called "Show Number Grouping Separator" in Tools>GeoRaptor>Visualisation.
         If it is ticked a number will be formatted with the thousands separator in Tools>Database>NLS eg 10000.000 will display as 10,000.000.
    * Sdo_Geometry display of all spaces in text between elements of the sdo_geometry array have been removed.
       This was done mainly to compact the sdo_geometry strings so that they are as small as possible when displaying or copying to clipboard.
    * Help pages added to the following dialogs with more to follow:
      -- Metadata Manager,
      -- Shapefile Importer and
      -- Layer Properties dialogs.
    * GeoRaptor menu entries renamed. New "Manage All Metadata" entry added to View>GeoRaptor menu.
    * Spatial Index creation dialog now supports additional index parameters and parallel build settings.
    * Metadata Manager overhauled:
      a. Shows:
         1. Metadata entries which have no underlying oracle object (orphan)
         2. Metadata entries for existing underlying objects (existing case)
         3. Database objects with sdo_geometry for which no metadata entry exists (new)
      b. All orphan/existing/missing colours for (a) can be set via Preferences>GeoRaptor>Visualisation
      c. All actions for main (bottom) metadata table are in a single right mouse click menu.
         Some entries will only appear if a single row is selection (metadata copy), others (delete and copy to clipboard) will appear for one or more.
      d. Can now switch between open connections to modify metadata of other objects in schemas other than the starting object.
      e. Buttons revamped.
    * Tab/Shapefile export:
      a. Export now supports NULL valued columns. Can be exported as an empty string (if DBase override in GeoRaptor Preferences is ticked) or
         as a predefined value eg NULL date => 1900-01-01 (set in new GeoRatptor Import/Export Preferences).
      b. Some work attempted on export of NLS strings (still not corrected).
      c. Objects with no rows now correctly processed.
    * Shapefile Import
      -- Bug relating to Linux file names corrected.
    * Fixed issue (identified by John O'Toole) with spatial index underlying a view not being used in map display.
    * Reinstated sdo_nn as the principal method for Identify (requested by John O'Toole).
    * Fixed problem with handling single click zoom in and out in GeoRaptor map etc.
    * Fixed problem with rendering lines from database item (identified by Vladimir Pek).The new "About GeoRaptor" should be read by all people installing GeoRaptor.
    Please, please consider registering your email address with our private email list so that we can get a feel for the sorts of people downloading and installing GeoRaptor.
    Please consider helping us with documentation or the internationalisation via translating properties files from English to your native language.
    GeoRaptor is written and maintained by people who use SQL Developer and Spatial every day but we don't pretend we know everything that users want: please let us know via our feature request page at SourceForge.
    We don't get paid for what we do so are always looking for additional help.
    Here are some of the requests we have had for improvements:
    1. MySQL access
    2. WMS access;
    3. Ability to import shapefile data into an existing table;
    4. Ability to processing multiple shapefiles into separate tables (current version can import one or more into a single target table);
    5. Ability to export/import layer definitions to give to others;
    6. Support for non-English character sets for varchar exports to shapefiles.Some are relatively simply, some require a lot of engineering work. For the latter, we are considering alternative funding methods to the currently completely free development approach.
    Thanks to the following for their invaluable assistance:
    Holger Labe, Germany
    John O'Toole, Ireland
    Vladimir Pek, Czech Republic
    Pieter Minnaar, Holland
    Olaf Iseeger, Germany
    Sandro Costa, Brazil;
    Marco Giana, Australia.regards
    Simon Greener
    Principal GeoRaptor Developer
    Edited by: Simon Greener on Sep 10, 2012 2:43 PM

    Simon,
    I will admit, I almost never use SQL Developer. I have been a long time Toad user, but for this tool, I fumbled around a bit and got everything up and running quickly.
    That said, I tried the new GeoRaptor tool using this tutorial (which is I think is close enough to get the jist). http://sourceforge.net/apps/mediawiki/georaptor/index.php?title=A_Gentle_Introduction:_Create_Table,_Metadata_Registration,_Indexing_and_Mapping
    As I stumble around it, I'll try and leave some feedback, and probably ask some rather stupid questions.
    Thanks for the effort,
    Bryan

  • Having trouble connecting SQL Developer to database on LINUX machine

    Having trouble connecting SQL Developer to database on LINUX machine
    Hello,
    I am trying to connect my windows 7 home premium machine to an oracle database 11g on a RedHat 5 machine using SQL Developer. i got this error message on SQL Developer
    Status : Failure - Test failed :The Network Adapter could not establish the connection
    on Linux
    LSNRCTL> status
    Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC1)))
    STATUS of the LISTENER
    Alias                     LISTENER
    Version                   TNSLSNR for Linux: Version 10.2.0.1.0 - Production
    Start Date                03-APR-2013 16:13:13
    Uptime                    7 days 22 hr. 16 min. 41 sec
    Trace Level               off
    Security                  ON: Local OS Authentication
    SNMP                      OFF
    Listener Parameter File   /u01/app/oracle/product/11.2.0/db_1/network/admin/listener.ora
    Listener Log File         /u01/app/oracle/product/11.2.0/db_1/network/log/listener.log
    Listening Endpoints Summary...
    (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1)))
    (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=172.X.X.X)(PORT=1521)))
    Services Summary...
    Service "PLSExtProc" has 1 instance(s).
    Instance "PLSExtProc", status UNKNOWN, has 1 handler(s) for this service...
    Service "orc11g" has 1 instance(s).
    Instance "orc11g", status READY, has 1 handler(s) for this service...
    Service "orc11gXDB" has 1 instance(s).
    Instance "orc11g", status READY, has 1 handler(s) for this service...
    Service "orc11g_XPT" has 1 instance(s).
    Instance "orc11g", status READY, has 1 handler(s) for this service...
    The command completed successfully
    LSNRCTL> and TNSPING
    tnsping 172.x.x.x
    TNS Ping Utility for Linux: Version 10.2.0.1.0 - Production on 11-APR-2013 14:32:17
    Copyright (c) 1997, 2005, Oracle.  All rights reserved.
    Used parameter files:
    /u01/app/oracle/product/11.2.0/db_1/network/admin/sqlnet.ora
    Used EZCONNECT adapter to resolve the alias
    Attempting to contact (DESCRIPTION=(CONNECT_DATA=(SERVICE_NAME=172.x.x.x))(ADDRESS=(PROTOCOL=TCP)(HOST=172.x.x.x)(PORT=1521)))
    OK (0 msec)
    [oracle@ltebilling ~]$Tnsnames.ora On Linux ,
    ORC11G =
    (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = 172.x.x.x)(PORT = 1521))
    (CONNECT_DATA =
    (SERVER = DEDICATED)
    (SERVICE_NAME = orc11g)
    )Listner on Linux ,
    SID_LIST_LISTENER =
    (SID_LIST =
    (SID_DESC =
    (SID_NAME = PLSExtProc)
    (ORACLE_HOME = /u01/app/oracle/product/11.2.0/db_1)
    (PROGRAM = extproc)
    LISTENER =
    (DESCRIPTION_LIST =
    (DESCRIPTION =
    (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))
    (ADDRESS = (PROTOCOL = TCP)(HOST = 172.x.x.x)(PORT = 1521))
    )/ect/hosts Linux ,
    # Do not remove the following line, or various programs
    # that require network functionality will fail.
    127.0.0.1               localhost.localdomain localhost
    172.x.x.x             LTEBillingand there is no problem of ping linux from windows
    Edited by: user11309581 on Apr 11, 2013 3:16 PM

    yes really i'm already enaple the port 1521 and SELINUX=disabled
    [root@ltebilling ~]# /etc/init.d/iptables status
    Table: filter
    Chain INPUT (policy ACCEPT)
    num  target     prot opt source               destination
    1    RH-Firewall-1-INPUT  all  --  0.0.0.0/0            0.0.0.0/0
    Chain FORWARD (policy ACCEPT)
    num  target     prot opt source               destination
    1    RH-Firewall-1-INPUT  all  --  0.0.0.0/0            0.0.0.0/0
    Chain OUTPUT (policy ACCEPT)
    num  target     prot opt source               destination
    Chain RH-Firewall-1-INPUT (2 references)
    num  target     prot opt source               destination
    1    ACCEPT     all  --  0.0.0.0/0            0.0.0.0/0
    2    ACCEPT     icmp --  0.0.0.0/0            0.0.0.0/0           icmp type 255
    3    ACCEPT     esp  --  0.0.0.0/0            0.0.0.0/0
    4    ACCEPT     ah   --  0.0.0.0/0            0.0.0.0/0
    5    ACCEPT     udp  --  0.0.0.0/0            224.0.0.251         udp dpt:5353
    6    ACCEPT     udp  --  0.0.0.0/0            0.0.0.0/0           udp dpt:631
    7    ACCEPT     tcp  --  0.0.0.0/0            0.0.0.0/0           tcp dpt:631
    8    ACCEPT     all  --  0.0.0.0/0            0.0.0.0/0           state RELATED,ESTABLISHED
    9    ACCEPT     tcp  --  0.0.0.0/0            0.0.0.0/0           state NEW tcp dpt:1521
    10   ACCEPT     tcp  --  0.0.0.0/0            0.0.0.0/0           state NEW tcp dpt:22
    11   REJECT     all  --  0.0.0.0/0            0.0.0.0/0           reject-with icmp-host-prohibitedbut from windows system when i'm try tnsping i got this error
    C:\Windows\system32>tnsping orc11g
    TNS Ping Utility for 64-bit Windows: Version 11.2.0.1.0 - Production on 11-APR-2
    013 14:44:09
    Copyright (c) 1997, 2010, Oracle.  All rights reserved.
    Used parameter files:
    D:\app\ubai\product\11.2.0\dbhome_2\network\admin\sqlnet.ora
    Used TNSNAMES adapter to resolve the alias
    Attempting to contact (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = 172.x.x
    .x)(PORT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = orc11g))
    TNS-12535: TNS:operation timed out
    C:\Windows\system32>

  • Not able to connect db using developers(plsql developer,sql developer)

    Hi,
    I used to work on plsql developer, but since from few days i am not able to connect to it, so i have installed sql developer still i am not able to connect to database.
    I can connect to the database using sql*plus. dont know what happend suddenly i have not changed any settings.
    I am getting the error when connecting sql developer: Status : Failure -Test failed: IO Error: The Network Adapter could not establish the connection
    when connecting through plsql developer getting the error: ora-12545 connect failed because target host or object does not exist
    Please help.
    Thanks,
    Vinod

    Wrong forum - please repost in the SQL Developer forum, edit this post to include the link to the SQL Developer thread and then mark this as ANSWERED.
    SQL Developer
    >
    when connecting through plsql developer getting the error: ora-12545 connect failed because target host or object does not exist
    >
    In you post on the other forum include your 4 digit Oracle version and the version of SQL Developer that you are using.
    Also provide the step by step details of how you are trying to create the new connection.
    The error message is telling you that you are using a server or host name that does not exist.

  • SQL Developer 2.1: Problem exporting and importing unit tests

    Hi,
    I have created several unit tests on functions that are within packages. I wanted to export these from one unit test repository into another repository on a different database. The export and import work fine, but when running the tests on the imported version, there are lots of ORA-06550 errors. When debugging this, the function name is missing in the call, i.e. it is attempting <SCHEMA>.<PACKAGE> (parameters) instead of <SCHEMA>.<PACKAGE>.<FUNCTION> (parameters).
    Looking in the unit test repository itself, it appears that the OBJECT_CALL column in the UT_TEST table is null - if I populate this with the name of the function, then everything works fine. Therefore, this seems to be a bug with export and import, and it is not including this in the XML. The same problem happens whether I export a single unit test or a suite of tests. Can you please confirm whether this is a bug or whether I am doing something wrong?
    Thanks,
    Pierre.

    Hi Pierre,
    Thanks for pointing this out. Unfortunately, it is a bug on our side and you have found the (ugly) "work-around".
    Bug 9236694 - 2.1: OTN: UT_TEST.OBJECT_CALL COLUMN NOT EXPORTED/IMPORTED
    Brian Jeffries
    SQL Developer Team

  • Unit testing packages in sql developer

    It appears that the specify parameters window is blank for packaged functions which means the test call fails when run. Is this a grant or synonym issue ( or something similar ) or is there an issue with testing packages via the unit test interface of sql developer. Thanks in advance.

    Seems that you cannot right click on the packaged schema object from the schema connection i.e. you have to create the test from the unit test tab and then choose the object type i.e select packages and then the packaged function or procedure. This method results in the Specify Parameters window having the correct signature displayed. Procedures or methods can be created via the unit test tab or the active connection tab.

  • SQL Developer Unit Testing - Validation with PL/SQL

    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

    Probably not the answer you're looking for, but back when I was playing around with the Unit Test stuff, I didn't have sys privs, and the DBAs were a little busy at the time to set a up a repository for me. Rather than wait, I installed Oracle XE on my machine and created a small dev schema and deployed unit test to that. It's so much easier to perform quick proof of concepts when you have full control.

  • SQL Developer 3.0 Unit Test

    Hi all,
    I'm hoping that one of you very knowledgeable individuals may be able to assist me!
    I'm an APEX developer, and I'm trying to make use of Hudson (www.hudson-ci.org) to automate my build process. I can successfully check files out of a source control repository and run them on my database, but I'm falling down when I try to use SQL Developer 3.0 from the command line to execute some unit tests.
    My test environment is a Windows XP SP3 machine running an 11g DB, APEX 4.1 and SQL Developer 3.0. In SQL Developer, I've set up a connection called APPHOME and currently, my unit test repository is on the same connection. If I open a command prompt and execute:
    C:\sqldeveloper\bin>ututil -run -suite -name TEST_PROCEDURE_SUITE -repo APPHOME -db APPHOME -log 1
    It works fine. The suite of tests execute OK, I get UT_SUCCESS back and when I look in SQL Developer, the result is there.
    However, if in a Hudson project I include an instruction that tries to fire exactly the same command, I get a response of: "Connection not found: APPHOME".
    Do I need to do anything special to ensure that ututil will be able to see the connection? The only thing that I can think of is that when I execute ututil from the command line, it does so as the logged in user (me, and I'm the one who has created the connections in SQL Developer) whereas when its fired by Hudson, it is executing as some other user that doesn't have my connections?
    Does anybody have any thoughts about this?
    Thanks in advance!
    Nick

    Hi Nick,
    I think your diagnosis is correct i.e. the connections are specific to your user. To resolve, you can try logging onto the Hudson server as the user that will run ututil, run up sqldeveloper client and import the connections into that user.
    I hope this helps.
    Philip Richens
    SQLDEV Development Team

  • SQL Developer 3.0 Unit Testing

    Hi folks,
    Firstly, let me say thanks for all the hard work that has gone into the improvements made in SQL Developer 3.0. I've been trailing EA3 for the past few days, and am so far very impressed.
    My development team are particularly interested in the improvements made to the Unit Test module. We have previously created a number of tests/test suites in 2.1, but when we select to connect to the old test case repository schema, 3.0 tells me that it can not find the repository. (Apologises, I do not have my development box in front of me, so I can't quote the exact message).
    Is there anything I can do to get it to recognise the old repository? I'd prefer not to have to recreate all of our existing tests...
    Thanks in advance,
    Nick

    Hi Mikka,
    Only simple PL/SQL Records are currently supported i.e. those that do not contain repeating or optional components and where all the components are themselves supported. This restriction is in place due to the fact that we use JDBC as the parameter passing mechanism which does not directly support the PL/SQL Record type.
    ANYTYPE and ANYDATA are not currently supported as they have a dynamic value type and therefore must be programmatically set. In the future, it may be possible to support these through the dynamic value and and validation features.
    This will remain so for the final version.
    Regards,
    Richard

  • Unit Test in SQL Developer 2.1: Automated Builds

    Hi,
    I am interested to know if the new Unit Testing framework can be accessed via API so the test execution is initiated from automated build process.
    Regards,
    Vadim

    I am having a problem with the unit testing command line.
    I am attempting to run the unit testing using the command line interface.
    I can connect to UNIT_TEST_REPOS schema in SQL developer.
    I am successfully running units test and suites in SQL developer.
    UNIT_TEST_REPOS, RCSV1 and DEVER users are granted on the UT_REPO_USER role and UNIT_TEST_REPOS and DEVER on the UT_REPO_ADMINISTRATOR.
    The following commands result in an error box saying "No Repository was found on the selected connection, you need to create a repository." (The HELP button apparently does nothing. The OK button closes the box.)
    C:\Program Files\sqldeveloper\sqldeveloper\bin>UtUtil -exp -test -name RCSV1_RCS_SECURITY.GET_LDAP_BASE -repo unit_test_repos -file c:\ut_xml\test.xml
    Unable to open repository
    C:\Program Files\sqldeveloper\sqldeveloper\bin>UtUtil -run -test -name RCSV1_RCS_SECURITY.GET_LDAP_BASE -repo unit_test_repos -db dever
    Unable to open repository
    C:\Program Files\sqldeveloper\sqldeveloper\bin>UtUtil -run -test -name RCSV1_RCS_SECURITY.GET_LDAP_BASE -repo dever -db dever
    Unable to open repository
    I would guess that I am not supplying the correct connection info.
    My last comment triggered an idea. It turns out that the connection names required are those connections named in SQL developer. In my case, they are not the same as the schema names. The following command worked as advertised.
    C:\Program Files\sqldeveloper\sqldeveloper\bin>UtUtil -run -test -name RCSV1_RCS_SECURITY.GET_LDAP_BASE -repo UNIT_TEST -db DeverLocal
    The ANT target is
    <target name="UnitTests">
    <exec executable="cmd" dir="${sqldev.bin.dir}">
    <arg value="/c"/>
    <arg value="UtUtil -run -suite -name RCSV1 -repo UNIT_TEST -db DeverLocal"/>
    </exec>
    </target>
    Regards,
    Bill

  • Unit Test - Select current repository disabled in SQL Developer 4.0

    Hi,
    I am now using Oracle SQL Developer 4.0 and I want to use Unit Testing. However, when I go to Tools-> Unit Testing -> Select Current Repository, the option is disabled. However, it is working and active when using SQL Developer 3.0
    Anyone faced the same problem??

    I could finally solve it.
    Go to the View -> Test Units
    Then the Test Units box will open in the left side of the SQL Developer and you will be able to access the Tools-> Unit Testing -> Select Current Repository
    I hope this help everybody here

Maybe you are looking for