public function testDownloadingByIncorrectPathThrowsException() { $this->setExpectedException(NotFoundException::class); $guzzle = $this->buildGuzzleFromResponses([$this->buildResponseFromStub(200, [], 'authorize_account.json'), $this->buildResponseFromStub(400, [], 'download_by_incorrect_path.json')]); $client = new Client('testId', 'testKey', ['client' => $guzzle]); $client->download(['BucketName' => 'test-bucket', 'FileName' => 'path/to/incorrect/file.txt']); }