mirror of
https://github.com/zhigang1992/react-native-firebase.git
synced 2026-04-23 20:10:05 +08:00
[database][ios] error codes now correctly lower cased - incorrect tests updated to match
This commit is contained in:
@@ -26,7 +26,6 @@ const testGroups = [
|
||||
pushTests, onTests, onValueTests, onChildAddedTests, onceTests, updateTests,
|
||||
removeTests, setTests, transactionTests, queryTests, refTests, isEqualTests,
|
||||
priorityTests,
|
||||
onValueTests, onChildAddedTests,
|
||||
offTests,
|
||||
];
|
||||
|
||||
|
||||
@@ -342,7 +342,7 @@ function onTests({ describe, context, it, firebase, tryCatch }) {
|
||||
'Database: Client doesn\'t have permission to access the desired data. (database/permission-denied).',
|
||||
);
|
||||
|
||||
error.code.should.eql('DATABASE/PERMISSION-DENIED');
|
||||
error.code.should.eql('database/permission-denied');
|
||||
|
||||
// test ref matches
|
||||
error.ref.path.should.eql(invalidRef.path);
|
||||
|
||||
@@ -62,7 +62,7 @@ function onceTests({ describe, firebase, it, tryCatch }) {
|
||||
|
||||
const failureCb = tryCatch((error) => {
|
||||
// Assertion
|
||||
error.code.includes('DATABASE/PERMISSION-DENIED').should.be.true();
|
||||
error.code.includes('database/permission-denied').should.be.true();
|
||||
resolve();
|
||||
}, reject);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user