You have used the log & fail antipattern in many places. Please fix all of
these places. Perhaps it existes already, but please fix it. Just throw the
exceptions from the methods if those are not expected exceptions.

Tharinud, please assist in fixing these test failures.

public void login() throws Exception {
+        ClientConnectionUtil.waitForPort(9443);
+        String sessionCookie = util.login();
+         try {
+            initStubs(sessionCookie);
+        } catch (AxisFault axisFault) {
+            log.error("Error initializing service stubs. Not running
tests.." + axisFault);
+            Assert.fail("Error initializing service stubs. Not running
tests..");
+            return;
+        }
+     }

On Thu, Dec 22, 2011 at 5:29 PM, Sinthuja Ragendran <[email protected]>wrote:

> Hi,
>
> I have migrated the BAM integration test to TestNG. Patch is attached in
> https://wso2.org/jira/browse/CARBON-12104
>
> Thanks,
> Sinthuja.
>
>
> On Thu, Dec 22, 2011 at 5:17 PM, Nuwan Dias <[email protected]> wrote:
>
>> Hi,
>>
>> Migrated some JUnit integration test cases to TestNG in the ESB. Patch
>> attached at https://wso2.org/jira/browse/ESBJAVA-859.
>>
>> Thanks,
>> NuwanD.
>>
>>
>> On Thu, Dec 22, 2011 at 1:24 PM, Achala Aponso <[email protected]> wrote:
>>
>>>
>>>
>>> On Thu, Dec 22, 2011 at 1:18 PM, Afkham Azeez <[email protected]> wrote:
>>>
>>>>
>>>>
>>>> On Thu, Dec 22, 2011 at 1:13 PM, Achala Aponso <[email protected]> wrote:
>>>>
>>>>> Hi,
>>>>>
>>>>> No, i haven't committed the GS Tests to the trunk. but i committed the
>>>>> existing MS test cases of branch to the trunk.
>>>>>
>>>>
>>>> MS stuff needs to be migrated to TestNG I guess.
>>>>
>>>
>>>
>>>>  Yes , Maninda is working on it.
>>>>
>>>>>
>>>>> On Thu, Dec 22, 2011 at 1:09 PM, Afkham Azeez <[email protected]> wrote:
>>>>>
>>>>>> Have you committed these changes to trunk?
>>>>>>
>>>>>>
>>>>>> On Thu, Dec 22, 2011 at 1:08 PM, Achala Aponso <[email protected]>wrote:
>>>>>>
>>>>>>> Hi,
>>>>>>>
>>>>>>> GS has following Test modules
>>>>>>> User Management
>>>>>>> Gadgetrepo
>>>>>>> Dashboard
>>>>>>> Theme
>>>>>>> OAuth
>>>>>>>
>>>>>>> I have migrated the Test cases of User Management( 10 Tests ) to
>>>>>>> TestNG and the tests are passing. And also converted the 
>>>>>>> GetGadgetListTest
>>>>>>> of Gadgetrepo successfully ( 2 Tests). I have added LoginLogoutTestCase 
>>>>>>> (1
>>>>>>> Test) and SecurityVerificationTestCase (1 Test).
>>>>>>>  Added the missing test cases of MS to the trunk and fixed the
>>>>>>> issues.
>>>>>>>
>>>>>>> On Thu, Dec 22, 2011 at 11:31 AM, Subash Chaturanga <[email protected]
>>>>>>> > wrote:
>>>>>>>
>>>>>>>>
>>>>>>>> Hi,
>>>>>>>> In GReg there are five integration test modules.
>>>>>>>>
>>>>>>>>       - app-remote-registry-test
>>>>>>>>       - registry-metadata-test
>>>>>>>>       - registry-handler-test
>>>>>>>>       - registry-ws-api-test
>>>>>>>>       - registry-resource-test
>>>>>>>>
>>>>>>>> I have added a new registry-integration-test module there and new
>>>>>>>> TestNG stuff are there as separate packages.
>>>>>>>> And there I have additionally added a LoginLogout test case and a
>>>>>>>> SecurityVerification test case. Currently I have migrated
>>>>>>>> the registry-handler-test into TestNG and in the process of
>>>>>>>> making registry-handler-test run all integration tests pass before move
>>>>>>>> into others.
>>>>>>>>
>>>>>>>>
>>>>>>>> On Thu, Dec 22, 2011 at 8:36 AM, Shelan Perera <[email protected]>wrote:
>>>>>>>>
>>>>>>>>> Hi,
>>>>>>>>>
>>>>>>>>> We have completed DSS test migration to TestNg which included 45
>>>>>>>>> tests.I am preparing the patch and will attach it to the JIRA.
>>>>>>>>>
>>>>>>>>> Thanks
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On Thu, Dec 22, 2011 at 8:13 AM, Sinthuja Ragendran <
>>>>>>>>> [email protected]> wrote:
>>>>>>>>>
>>>>>>>>>> Hi,
>>>>>>>>>>
>>>>>>>>>> I have migrated the all existing test cases to TestNG, but most
>>>>>>>>>> of the tests are failing due to the some issues in the existing test 
>>>>>>>>>> cases,
>>>>>>>>>> therefore fixing those one-by-one.
>>>>>>>>>>
>>>>>>>>>> The testing basically includes,
>>>>>>>>>>     - Login (1 Test)
>>>>>>>>>>     - Monitored Servers (3 Tests)
>>>>>>>>>>     - Data collection (4 Tests)
>>>>>>>>>>     - Summary Generation (1 Test)
>>>>>>>>>>     - Security Verification (1 Test)
>>>>>>>>>>
>>>>>>>>>> Login, Summary Generation and adding server test in monitored
>>>>>>>>>> sever tests are passing, fixing the rest of the tests.
>>>>>>>>>>
>>>>>>>>>> Thanks,
>>>>>>>>>> Sinthuja
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> On Wed, Dec 21, 2011 at 10:54 PM, Keheliya Gallaba <
>>>>>>>>>> [email protected]> wrote:
>>>>>>>>>>
>>>>>>>>>>> Hi,
>>>>>>>>>>>
>>>>>>>>>>> Existing Integration tests in BPS consist of following modules.
>>>>>>>>>>> Login - (1 Test)
>>>>>>>>>>> Management - (5 Tests)
>>>>>>>>>>> BPEL - (8 Tests)
>>>>>>>>>>> Instance Cleanup - (1 Test)
>>>>>>>>>>> External Data sources - (1 Test)
>>>>>>>>>>> BPEL Security - (2 Tests)
>>>>>>>>>>>
>>>>>>>>>>> I have completed migrating Management tests, then added
>>>>>>>>>>> Login/Logout, SecurityVerifier tests. Hoping to complete rest of the
>>>>>>>>>>> migration within this week.
>>>>>>>>>>>
>>>>>>>>>>> BTW, since some of us are presenting papers in the ERU Research
>>>>>>>>>>> Symposium at UOM tomorrow at different time slots, I think it might 
>>>>>>>>>>> be
>>>>>>>>>>> difficult to arrange a meeting tomorrow.
>>>>>>>>>>>
>>>>>>>>>>> Thanks,
>>>>>>>>>>> Keheliya
>>>>>>>>>>>
>>>>>>>>>>> On Wed, Dec 21, 2011 at 8:28 PM, Afkham Azeez <[email protected]>wrote:
>>>>>>>>>>>
>>>>>>>>>>>> We need to have a meeting tomorrow to check on the progress of
>>>>>>>>>>>> the test migration effort. I have so far received a patch from 
>>>>>>>>>>>> Suho with
>>>>>>>>>>>> the CEP migration & CEP integration tests are working fine now. 
>>>>>>>>>>>> How about
>>>>>>>>>>>> the others?
>>>>>>>>>>>>
>>>>>>>>>>>> On Fri, Dec 16, 2011 at 3:32 PM, Afkham Azeez 
>>>>>>>>>>>> <[email protected]>wrote:
>>>>>>>>>>>>
>>>>>>>>>>>>> The following team of people will be working on product
>>>>>>>>>>>>> integration testing over the next 3 working weeks. They will 
>>>>>>>>>>>>> start working
>>>>>>>>>>>>> on this immediately. The objective is to improve the code 
>>>>>>>>>>>>> coverage of all
>>>>>>>>>>>>> products. Nobody has been assigned from G-Reg & Carbon core.
>>>>>>>>>>>>>
>>>>>>>>>>>>> BPS - Keheliya
>>>>>>>>>>>>> BAM - Sinthuja
>>>>>>>>>>>>> DSS - Shelan and Lakmali
>>>>>>>>>>>>> Achala and Maninda will be working on GS and MS
>>>>>>>>>>>>> GS - Achala
>>>>>>>>>>>>> MS - Maninda
>>>>>>>>>>>>> CEP - Suhothayan
>>>>>>>>>>>>> BRS - Ishara
>>>>>>>>>>>>> AS - KasunG
>>>>>>>>>>>>> IS - Johann
>>>>>>>>>>>>> ESB - Nuwan and Ishan
>>>>>>>>>>>>> G-Reg - ?
>>>>>>>>>>>>> Carbon Core - ?
>>>>>>>>>>>>>
>>>>>>>>>>>>> *Plan for each product*
>>>>>>>>>>>>> 1. Spend up to one day learning TestNG
>>>>>>>>>>>>> 2. Migrate existing integration tests to TestNG. This has
>>>>>>>>>>>>> already been done for Carbon core, AS & BRS
>>>>>>>>>>>>> 3. Fix all failing integration tests
>>>>>>>>>>>>> 4. Add SecurityVerification test to each product
>>>>>>>>>>>>> 5. Identify the functional areas of each product & add
>>>>>>>>>>>>> integration tests
>>>>>>>>>>>>>
>>>>>>>>>>>>> *Best Practices*
>>>>>>>>>>>>> 1. No sysouts after running tests. Use assert statements.
>>>>>>>>>>>>> 2. Comments & test descriptions should be adde
>>>>>>>>>>>>> 3. Follow coding conventions
>>>>>>>>>>>>> 4. Do not follow the "Catch & Fail" antipattern [0]. If
>>>>>>>>>>>>> exceptions are expected, use the @ExpectedExceptions [1] 
>>>>>>>>>>>>> annotation. Throw
>>>>>>>>>>>>> all unexpected exceptions from the test methods so that these 
>>>>>>>>>>>>> tests result
>>>>>>>>>>>>> in errors, not failures.
>>>>>>>>>>>>>
>>>>>>>>>>>>> Team, please make this an opportunity to learn & master the
>>>>>>>>>>>>> art of unit & integration testing.
>>>>>>>>>>>>>
>>>>>>>>>>>>> Thanks
>>>>>>>>>>>>> Azeez
>>>>>>>>>>>>>
>>>>>>>>>>>>> 0.
>>>>>>>>>>>>> http://www.exubero.com/junit/antipatterns.html#Catching_Unexpected_Exceptions
>>>>>>>>>>>>> 1.
>>>>>>>>>>>>> http://testng.org/javadoc/org/testng/annotations/ExpectedExceptions.html
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> --
>>>>>>>>>>>>> *Afkham Azeez*
>>>>>>>>>>>>> Director of Architecture; WSO2, Inc.; http://wso2.com
>>>>>>>>>>>>> Member; Apache Software Foundation; http://www.apache.org/
>>>>>>>>>>>>> * <http://www.apache.org/>**
>>>>>>>>>>>>> email: **[email protected]* <[email protected]>* cell: +94 77
>>>>>>>>>>>>> 3320919
>>>>>>>>>>>>> blog: **http://blog.afkham.org* <http://blog.afkham.org>*
>>>>>>>>>>>>> twitter: 
>>>>>>>>>>>>> **http://twitter.com/afkham_azeez*<http://twitter.com/afkham_azeez>
>>>>>>>>>>>>> *
>>>>>>>>>>>>> linked-in: **http://lk.linkedin.com/in/afkhamazeez*
>>>>>>>>>>>>> *
>>>>>>>>>>>>> *
>>>>>>>>>>>>> *Lean . Enterprise . Middleware*
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> --
>>>>>>>>>>>> *Afkham Azeez*
>>>>>>>>>>>> Director of Architecture; WSO2, Inc.; http://wso2.com
>>>>>>>>>>>> Member; Apache Software Foundation; http://www.apache.org/
>>>>>>>>>>>> * <http://www.apache.org/>**
>>>>>>>>>>>> email: **[email protected]* <[email protected]>* cell: +94 77 3320919
>>>>>>>>>>>> blog: **http://blog.afkham.org* <http://blog.afkham.org>*
>>>>>>>>>>>> twitter: 
>>>>>>>>>>>> **http://twitter.com/afkham_azeez*<http://twitter.com/afkham_azeez>
>>>>>>>>>>>> *
>>>>>>>>>>>> linked-in: **http://lk.linkedin.com/in/afkhamazeez*
>>>>>>>>>>>> *
>>>>>>>>>>>> *
>>>>>>>>>>>> *Lean . Enterprise . Middleware*
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>> Carbon-dev mailing list
>>>>>>>>>>>> [email protected]
>>>>>>>>>>>> http://mail.wso2.org/cgi-bin/mailman/listinfo/carbon-dev
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> --
>>>>>>>>>>> Keheliya Gallaba
>>>>>>>>>>> Software Engineer
>>>>>>>>>>> WSO2 Inc.
>>>>>>>>>>>
>>>>>>>>>>> E-mail: keheliya AT wso2.com
>>>>>>>>>>> M: +94 71 551 8881
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> _______________________________________________
>>>>>>>>>>> Carbon-dev mailing list
>>>>>>>>>>> [email protected]
>>>>>>>>>>> http://mail.wso2.org/cgi-bin/mailman/listinfo/carbon-dev
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> _______________________________________________
>>>>>>>>>> Carbon-dev mailing list
>>>>>>>>>> [email protected]
>>>>>>>>>> http://mail.wso2.org/cgi-bin/mailman/listinfo/carbon-dev
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> *Shelan Perera*
>>>>>>>>>
>>>>>>>>> Software Engineer
>>>>>>>>> **
>>>>>>>>> *WSO2, Inc. : wso2.com*
>>>>>>>>> lean.enterprise.middleware.
>>>>>>>>>
>>>>>>>>> *Home Page*  :    shelan.org
>>>>>>>>> *Blog*             : blog.shelan.org
>>>>>>>>> *Linked-i*n      :
>>>>>>>>> http://www.linkedin.com/pub/shelan-perera/a/194/465
>>>>>>>>> *Twitter*         :https://twitter.com/#!/shelan
>>>>>>>>>
>>>>>>>>> *Mobile*          : +94 772 604 402
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> _______________________________________________
>>>>>>>>> Carbon-dev mailing list
>>>>>>>>> [email protected]
>>>>>>>>> http://mail.wso2.org/cgi-bin/mailman/listinfo/carbon-dev
>>>>>>>>>
>>>>>>>>>
>>>>>>>>
>>>>>>>> Thanks
>>>>>>>> --
>>>>>>>>
>>>>>>>> Subash Chaturanga
>>>>>>>> Software Engineer
>>>>>>>> WSO2 Inc. http://wso2.com
>>>>>>>>
>>>>>>>> email - [email protected]
>>>>>>>> phone - 077 2225922
>>>>>>>>
>>>>>>>>
>>>>>>>> _______________________________________________
>>>>>>>> Carbon-dev mailing list
>>>>>>>> [email protected]
>>>>>>>> http://mail.wso2.org/cgi-bin/mailman/listinfo/carbon-dev
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> Achala Aponso
>>>>>>> Software Engineer; WSO2 Inc.; http://wso2.com,
>>>>>>> Email: [email protected] Mobile: +94 (77) 5234925
>>>>>>> Blog: http://achala11.blogspot.com/
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> _______________________________________________
>>>>>>> Carbon-dev mailing list
>>>>>>> [email protected]
>>>>>>> http://mail.wso2.org/cgi-bin/mailman/listinfo/carbon-dev
>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> *Afkham Azeez*
>>>>>> Director of Architecture; WSO2, Inc.; http://wso2.com
>>>>>> Member; Apache Software Foundation; http://www.apache.org/
>>>>>> * <http://www.apache.org/>**
>>>>>> email: **[email protected]* <[email protected]>* cell: +94 77 3320919
>>>>>> blog: **http://blog.afkham.org* <http://blog.afkham.org>*
>>>>>> twitter: 
>>>>>> **http://twitter.com/afkham_azeez*<http://twitter.com/afkham_azeez>
>>>>>> *
>>>>>> linked-in: **http://lk.linkedin.com/in/afkhamazeez*
>>>>>> *
>>>>>> *
>>>>>> *Lean . Enterprise . Middleware*
>>>>>>
>>>>>>
>>>>>> _______________________________________________
>>>>>> Carbon-dev mailing list
>>>>>> [email protected]
>>>>>> http://mail.wso2.org/cgi-bin/mailman/listinfo/carbon-dev
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Achala Aponso
>>>>> Software Engineer; WSO2 Inc.; http://wso2.com,
>>>>> Email: [email protected] Mobile: +94 (77) 5234925
>>>>> Blog: http://achala11.blogspot.com/
>>>>>
>>>>>
>>>>>
>>>>> _______________________________________________
>>>>> Carbon-dev mailing list
>>>>> [email protected]
>>>>> http://mail.wso2.org/cgi-bin/mailman/listinfo/carbon-dev
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>> *Afkham Azeez*
>>>> Director of Architecture; WSO2, Inc.; http://wso2.com
>>>> Member; Apache Software Foundation; http://www.apache.org/
>>>> * <http://www.apache.org/>**
>>>> email: **[email protected]* <[email protected]>* cell: +94 77 3320919
>>>> blog: **http://blog.afkham.org* <http://blog.afkham.org>*
>>>> twitter: 
>>>> **http://twitter.com/afkham_azeez*<http://twitter.com/afkham_azeez>
>>>> *
>>>> linked-in: **http://lk.linkedin.com/in/afkhamazeez*
>>>> *
>>>> *
>>>> *Lean . Enterprise . Middleware*
>>>>
>>>>
>>>> _______________________________________________
>>>> Carbon-dev mailing list
>>>> [email protected]
>>>> http://mail.wso2.org/cgi-bin/mailman/listinfo/carbon-dev
>>>>
>>>>
>>>
>>>
>>> --
>>> Achala Aponso
>>> Software Engineer; WSO2 Inc.; http://wso2.com,
>>> Email: [email protected] Mobile: +94 (77) 5234925
>>> Blog: http://achala11.blogspot.com/
>>>
>>>
>>>
>>> _______________________________________________
>>> Carbon-dev mailing list
>>> [email protected]
>>> http://mail.wso2.org/cgi-bin/mailman/listinfo/carbon-dev
>>>
>>>
>>
>> _______________________________________________
>> Carbon-dev mailing list
>> [email protected]
>> http://mail.wso2.org/cgi-bin/mailman/listinfo/carbon-dev
>>
>>
>
> _______________________________________________
> Carbon-dev mailing list
> [email protected]
> http://mail.wso2.org/cgi-bin/mailman/listinfo/carbon-dev
>
>


-- 
*Afkham Azeez*
Director of Architecture; WSO2, Inc.; http://wso2.com
Member; Apache Software Foundation; http://www.apache.org/
* <http://www.apache.org/>**
email: **[email protected]* <[email protected]>* cell: +94 77 3320919
blog: **http://blog.afkham.org* <http://blog.afkham.org>*
twitter: **http://twitter.com/afkham_azeez*<http://twitter.com/afkham_azeez>
*
linked-in: **http://lk.linkedin.com/in/afkhamazeez*
*
*
*Lean . Enterprise . Middleware*
_______________________________________________
Carbon-dev mailing list
[email protected]
http://mail.wso2.org/cgi-bin/mailman/listinfo/carbon-dev

Reply via email to