mirror of
https://github.com/crater-invoice/crater.git
synced 2025-10-28 20:21:10 -04:00
v6 update
This commit is contained in:
30
tests/Unit/Request/BulkExchangeRateTest.php
Normal file
30
tests/Unit/Request/BulkExchangeRateTest.php
Normal file
@ -0,0 +1,30 @@
|
||||
<?php
|
||||
|
||||
use Crater\Http\Requests\BulkExchangeRateRequest;
|
||||
|
||||
test('bulk exchange rate request validation rules', function () {
|
||||
$request = new BulkExchangeRateRequest();
|
||||
|
||||
$this->assertEquals(
|
||||
[
|
||||
'currencies' => [
|
||||
'required'
|
||||
],
|
||||
'currencies.*.id' => [
|
||||
'required',
|
||||
'numeric'
|
||||
],
|
||||
'currencies.*.exchange_rate' => [
|
||||
'required'
|
||||
],
|
||||
],
|
||||
$request->rules()
|
||||
);
|
||||
});
|
||||
|
||||
test('bulk exchange rate request authorize', function () {
|
||||
$request = new BulkExchangeRateRequest();
|
||||
|
||||
$this->assertTrue($request->authorize());
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user