diff options
author | Filipp Lepalaan <filipp@mac.com> | 2015-07-31 15:26:19 +0300 |
---|---|---|
committer | Filipp Lepalaan <filipp@mac.com> | 2015-07-31 15:26:19 +0300 |
commit | 1825df994ed8b944ddb74d5909a139eb2d333804 (patch) | |
tree | 3fea3d5962486d6d0c67e1fc145045e8b8bd7bed | |
parent | ad669af2ae55f2d0134f919daf16212161cf7bcf (diff) | |
download | gsxlib-1825df994ed8b944ddb74d5909a139eb2d333804.tar.gz gsxlib-1825df994ed8b944ddb74d5909a139eb2d333804.tar.bz2 gsxlib-1825df994ed8b944ddb74d5909a139eb2d333804.zip |
Updated carry-in repair test
-rw-r--r-- | runtests.php | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/runtests.php b/runtests.php index fa87c70..3075690 100644 --- a/runtests.php +++ b/runtests.php @@ -3,6 +3,7 @@ require_once('simpletest/autorun.php'); require_once('gsxlib.php'); + class GsxlibTest extends UnitTestCase { function setUp() { @@ -23,10 +24,13 @@ class GsxlibTest extends UnitTestCase function testCreateCarryInRepair() { $symptom = $this->gsx->fetchSymptomIssue($this->sn)->symptoms[0]; + $symptom_code = $symptom->reportedSymptomCode; + $issue = $this->gsx->fetchSymptomIssue(array('reportedSymptomCode' => $symptom_code)); + $issue_code = $issue->issues[0]->reportedIssueCode; $repairData = array( - 'shipTo' => '6191', 'serialNumber' => $this->sn, + 'shipTo' => $_ENV['GSX_SHIPTO'], 'diagnosedByTechId' => 'USA022SN', 'symptom' => 'Sample symptom', 'diagnosis' => 'Sample diagnosis', @@ -34,12 +38,12 @@ class GsxlibTest extends UnitTestCase 'unitReceivedTime' => '12:40 PM', 'notes' => 'A sample notes', 'poNumber' => '11223344', - 'popFaxed' => false, + 'popFaxed' => FALSE, 'orderLines' => array( - 'partNumber' => '076-1080', + 'partNumber' => '661-6049', 'comptiaCode' => '660', 'comptiaModifier' => 'A', - 'abused' => false + 'abused' => FALSE ), 'customerAddress' => array( 'addressLine1' => 'Address line 1', @@ -55,8 +59,8 @@ class GsxlibTest extends UnitTestCase 'lastName' => 'Customer lastname', 'primaryPhone' => '4088887766' ), - 'reportedSymptomCode' => $symptom->reportedSymptomCode, - 'reportedIssueCode' => 'IP025', + 'reportedSymptomCode' => $symptom_code, + 'reportedIssueCode' => $issue_code, ); $this->gsx->createCarryinRepair($repairData); |