mirror of
https://github.com/zhigang1992/DefinitelyTyped.git
synced 2026-06-05 06:40:35 +08:00
couchbase: fixed test
This commit is contained in:
@@ -4,10 +4,14 @@ import couchbase = require('couchbase');
|
||||
var db = new couchbase.Connection({ bucket: "default" }, function (err) {
|
||||
if (err) throw err;
|
||||
|
||||
db.set('testdoc', { name: 'Frank' }, function (err, result) {
|
||||
if (err) throw err;
|
||||
// TS 0.9.5 bug https://typescript.codeplex.com/workitem/2035, todo: remove cast after fix
|
||||
(<couchbase.Connection>db).set('testdoc', { name: 'Frank' }, function (err, result) {
|
||||
if (err) throw err;
|
||||
|
||||
db.get('testdoc', function (err, result) {
|
||||
var s: string = err.message;
|
||||
|
||||
// TS 0.9.5 bug https://typescript.codeplex.com/workitem/2035, todo: remove cast after fix
|
||||
(<couchbase.Connection>db).get('testdoc', function (err, result) {
|
||||
if (err) throw err;
|
||||
|
||||
console.log(result.value);
|
||||
|
||||
Reference in New Issue
Block a user