This commit is contained in:
Barış Soner Uşaklı
2018-03-03 12:31:20 -05:00
parent 7df191412d
commit 87c5dd34ea
2 changed files with 23 additions and 1 deletions

View File

@@ -27,6 +27,14 @@ describe('Key methods', function () {
});
});
it('should return null if key does not exist', function (done) {
db.get('doesnotexist', function (err, value) {
assert.ifError(err);
assert.equal(value, null);
done();
});
});
it('should return true if key exist', function (done) {
db.exists('testKey', function (err, exists) {
assert.ifError(err);