use email in update tests

This commit is contained in:
denisdulici 2020-03-19 19:00:18 +03:00
parent 7b0a5d8875
commit 7b53c61777
4 changed files with 8 additions and 8 deletions

View File

@ -58,12 +58,12 @@ class BillsTest extends FeatureTestCase
$bill = $this->dispatch(new CreateBill($request));
$request['contact_name'] = $this->faker->name;
$request['contact_email'] = $this->faker->safeEmail;
$this->loginAs()
->patch(route('bills.update', $bill->id), $request)
->assertStatus(200)
->assertSee($request['contact_name']);
->assertSee($request['contact_email']);
$this->assertFlashLevel('success');
}

View File

@ -59,12 +59,12 @@ class VendorsTest extends FeatureTestCase
$vendor = $this->dispatch(new CreateContact($request));
$request['name'] = $this->faker->name;
$request['email'] = $this->faker->safeEmail;
$this->loginAs()
->patch(route('vendors.update', $vendor->id), $request)
->assertStatus(200)
->assertSee($request['name']);
->assertSee($request['email']);
$this->assertFlashLevel('success');
}

View File

@ -76,12 +76,12 @@ class CustomersTest extends FeatureTestCase
$customer = $this->dispatch(new CreateContact($request));
$request['name'] = $this->faker->name;
$request['email'] = $this->faker->safeEmail;
$this->loginAs()
->patch(route('customers.update', $customer->id), $request)
->assertStatus(200)
->assertSee($request['name']);
->assertSee($request['email']);
$this->assertFlashLevel('success');
}

View File

@ -58,12 +58,12 @@ class InvoicesTest extends FeatureTestCase
$invoice = $this->dispatch(new CreateInvoice($request));
$request['contact_name'] = $this->faker->name;
$request['contact_email'] = $this->faker->safeEmail;
$this->loginAs()
->patch(route('invoices.update', $invoice->id), $request)
->assertStatus(200)
->assertSee($request['contact_name']);
->assertSee($request['contact_email']);
$this->assertFlashLevel('success');
}