const alice = await testEnv.authenticatedContext('alice');
await assertFails(await getDoc(doc(await alice.firestore(), '/users/abc_123')));
Here is my security rules
match /users/{userID} {
allow read: if
request.auth != null && // This is in line 7
request.auth.uid == userID &&
request.auth.uid == resource.data.userID;
allow delete: if false;
}
This is the log of the test that fails
Users tests
should not allow users to read other user's data:
FirebaseError:
false for 'get' @ L7
Checking the request data using the firebase emulator suite, the request has an auth value. It is not null. request.auth != null SHOULD return true but it always return false no matter what.
This is the test code that fails
Here is my security rules
This is the log of the test that fails
Checking the request data using the firebase emulator suite, the request has an auth value. It is not null.
request.auth != null
SHOULD return true but it always return false no matter what.any ideas what could be the cause of this issue?