Exemplo n.º 1
0
 public function test_can_update_address()
 {
     $user = $this->createUser();
     $address = $this->createAddress($user);
     $this->asUser($user)->visitAddressesIndexPage()->put($this->updateUrl($address), ['recipient' => '测试收件人', 'street' => '测试街道地址', 'phone' => '54321', 'city_id' => $cityId = Location::inRandomOrder()->city()->first()->id, 'postcode' => 'random-postcode'])->followRedirects()->seeSuccessMessage('修改成功')->seeAll('测试收件人', '测试街道地址', '54321', Location::find($cityId)->name, 'random-postcode');
 }