Fixes for tests
This commit is contained in:
parent
a89e51ebdc
commit
2438bf9284
|
|
@ -920,11 +920,25 @@ $this->account->forceDelete();
|
||||||
'balance' => 100,
|
'balance' => 100,
|
||||||
'number' => '12345',
|
'number' => '12345',
|
||||||
'status_id' => 2,
|
'status_id' => 2,
|
||||||
'discount' => 10,
|
'discount' => 0,
|
||||||
'po_number' => '1234',
|
'po_number' => '1234',
|
||||||
'public_notes' => 'Public',
|
'public_notes' => 'Public',
|
||||||
'private_notes' => 'Private',
|
'private_notes' => 'Private',
|
||||||
'terms' => 'Terms',
|
'terms' => 'Terms',
|
||||||
|
'tax_rate1' => 0,
|
||||||
|
'tax_rate2' => 0,
|
||||||
|
'tax_rate3' => 0,
|
||||||
|
'line_items' => [
|
||||||
|
[
|
||||||
|
'quantity' => 1,
|
||||||
|
'product_key' => 'product_key',
|
||||||
|
'notes' => 'notes',
|
||||||
|
'cost' => 100,
|
||||||
|
'custom_value1' => 'Custom 1',
|
||||||
|
'custom_value2' => 'Custom 2',
|
||||||
|
'custom_value3' => 'Custom 3',
|
||||||
|
]
|
||||||
|
]
|
||||||
]);
|
]);
|
||||||
|
|
||||||
$invoice->client->balance = 100;
|
$invoice->client->balance = 100;
|
||||||
|
|
@ -1284,6 +1298,20 @@ $this->account->forceDelete();
|
||||||
'public_notes' => 'Public',
|
'public_notes' => 'Public',
|
||||||
'private_notes' => 'Private',
|
'private_notes' => 'Private',
|
||||||
'terms' => 'Terms',
|
'terms' => 'Terms',
|
||||||
|
'tax_rate1' => 0,
|
||||||
|
'tax_rate2' => 0,
|
||||||
|
'tax_rate3' => 0,
|
||||||
|
'line_items' => [
|
||||||
|
[
|
||||||
|
'quantity' => 1,
|
||||||
|
'product_key' => 'product_key',
|
||||||
|
'notes' => 'notes',
|
||||||
|
'cost' => 100,
|
||||||
|
'custom_value1' => 'Custom 1',
|
||||||
|
'custom_value2' => 'Custom 2',
|
||||||
|
'custom_value3' => 'Custom 3',
|
||||||
|
]
|
||||||
|
]
|
||||||
]);
|
]);
|
||||||
|
|
||||||
$repo = new InvoiceRepository();
|
$repo = new InvoiceRepository();
|
||||||
|
|
@ -1455,7 +1483,7 @@ $this->account->forceDelete();
|
||||||
'balance' => 50,
|
'balance' => 50,
|
||||||
'number' => '1234',
|
'number' => '1234',
|
||||||
'status_id' => 2,
|
'status_id' => 2,
|
||||||
'discount' => 10,
|
'discount' => 0,
|
||||||
'po_number' => '1234',
|
'po_number' => '1234',
|
||||||
'public_notes' => 'Public',
|
'public_notes' => 'Public',
|
||||||
'private_notes' => 'Private',
|
'private_notes' => 'Private',
|
||||||
|
|
|
||||||
|
|
@ -53,7 +53,7 @@ class LateFeeTest extends TestCase
|
||||||
|
|
||||||
$this->makeTestData();
|
$this->makeTestData();
|
||||||
|
|
||||||
$this->withoutExceptionHandling();
|
// $this->withoutExceptionHandling();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -370,12 +370,12 @@ class LateFeeTest extends TestCase
|
||||||
|
|
||||||
$this->assertEquals(2, count($i->line_items));
|
$this->assertEquals(2, count($i->line_items));
|
||||||
|
|
||||||
try{
|
// try{
|
||||||
$i->service()->autoBill();
|
$i->service()->autoBill();
|
||||||
}
|
// }
|
||||||
catch(\Exception $e){
|
// catch(\Exception $e){
|
||||||
nlog($e->getMessage());
|
// nlog($e->getMessage());
|
||||||
}
|
// }
|
||||||
|
|
||||||
$i = $i->fresh();
|
$i = $i->fresh();
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue