stif/TestCombiner/src/TestCase.cpp
branchRCL_3
changeset 16 8f8df8006c40
parent 0 a03f92240627
child 18 3406c99bc375
--- a/stif/TestCombiner/src/TestCase.cpp	Wed Jun 09 11:23:41 2010 +0300
+++ b/stif/TestCombiner/src/TestCase.cpp	Mon Jun 21 17:25:56 2010 +0300
@@ -336,6 +336,7 @@
 CTCTestCase::CTCTestCase( CTestCombiner* testCombiner,
                           TInt aExpectedResult,
                           TFullTestResult::TCaseExecutionResult aCategory,
+                          const TDesC& aTestCaseArguments,
                           CTCTestModule* aModule ): //--PYTHON
     CTestCase( testCombiner, aExpectedResult, aCategory, ECaseLocal, aModule ), //--PYTHON
     iResultPckg( iResult )
@@ -365,12 +366,13 @@
 */
 
 void CTCTestCase::ConstructL( TDesC& aModuleName,
-                              TDesC& aTestId )
+                              TDesC& aTestId,
+                              const TDesC& aTestCaseArguments )
     {
     __ASSERT_ALWAYS( aModuleName.Length() < KMaxFileName, User::Leave( KErrArgument ) );
     CTestCase::ConstructL( aTestId );
     iModuleName = aModuleName.AllocL();
-    
+    iTestCaseArguments = aTestCaseArguments.AllocL();
     }
 
 /*
@@ -397,17 +399,18 @@
                                 TDesC& aModuleName,
                                 TDesC& aTestId,
                                 TInt aExpectedResult,
-                                TFullTestResult::TCaseExecutionResult
-                                    aCategory,
+                                TFullTestResult::TCaseExecutionResult aCategory,
+                                const TDesC& aTestCaseArguments,
                                 CTCTestModule* aModule ) //--PYTHON
     {
     CTCTestCase* self = new (ELeave) CTCTestCase( testCombiner,
                                                    aExpectedResult,
                                                    aCategory,
+                                                   aTestCaseArguments,
                                                    aModule ); //--PYTHON
      
     CleanupStack::PushL( self );
-    self->ConstructL( aModuleName, aTestId );
+    self->ConstructL( aModuleName, aTestId, aTestCaseArguments );
     CleanupStack::Pop();
     return self;
      
@@ -475,6 +478,7 @@
     
     delete iProgress;
     delete iModuleName;
+    delete iTestCaseArguments;
     
     delete iCommand;
     }
@@ -484,6 +488,34 @@
 
      Class: CTCTestCase
 
+     Method: TestCaseArguments
+
+     Description: Get test case arguments
+
+     Parameters: None.
+
+     Return Values: Test case arguments.
+
+     Errors/Exceptions: None.
+
+     Status: Proposal
+    
+-------------------------------------------------------------------------------
+*/
+const TDesC& CTCTestCase::TestCaseArguments() const 
+    {
+    if ( iTestCaseArguments !=NULL ) 
+        {
+        return *iTestCaseArguments; 
+        }
+    return KNullDesC;
+    }
+
+/*
+-------------------------------------------------------------------------------
+
+     Class: CTCTestCase
+
      Method: DoCancel
 
      Description: Derived from CActive, handles the Cancel.