expectExceptionMessage('Missing Access Token'); $api->project()->list(); } public function testInvalidProjectUidShouldThrowError() { $api = new Memsource('fakeToken'); $this->expectException(\Exception::class); $api->project()->get('invalidProjectUid'); } }