Closed raisen closed 8 years ago
@raisen hi!
We have supported chrome.storage
namespace since 1.0.0 version.
I have no problems with it.
function getData(key, callback) {
return chrome.storage.local.get(key, callback);
}
describe.only('chrome.storage.local.get', function () {
before(function () {
chrome.storage.local.get.yields('1');
});
it('should returns 1', function () {
getData('data', function (result) {
console.log('result', result); // 1
assert.equal(result, '1');
});
});
});
Can you show me your test case?
Oh, I see, I thought there was a dummy storage service implemented, but I have to specify that yields to a value first. Got it, thank you!
When I invoke
chrome.storage.local.get (string key, function callback)
, callback doesn't seem to be called. Is it supposed to be called?