Checklist for LBUser implementation in iOS and Android SDKs.
Basic auth worklow:
- Login as an existing user (email + password).
- All REST calls are using the access token obtained in step 1
- Log out
Advanced:
_doGetResourceTree: function(params, done) { | |
this._debuggerClient.evaluateGlobal('process.argv[1]', function(err, argv1) { | |
if (err) return done(err); | |
this._scriptStorage.findApplicationRoot(argv1, function(root) { | |
this._scriptStorage.findAllScripts(root, function(err, files) { | |
if (err) return done(err); | |
return done(null, this._createResourceTreeResponse(files)); | |
}.bind(this)); | |
}.bind(this)); | |
}.bind(this)); |
// Set this to the directory where you have node sources | |
// The test uses node's test certificates for the TLS server | |
var PATH_TO_NODE_SOURCES = '/Users/bajtos/src/node'; | |
/** Usage ** | |
1. Start a SSL server in terminal 1 | |
$ openssl s_server -cert test_cert.pem -key test_key.pem | |
(..lots of SSL logs..) | |
2. Run the client in terminal 2 - don't reuse sessions |
pom.withXml { | |
def root = asNode() | |
def deps = new Node(root, 'dependencies') | |
configurations.compile.allDependencies.each { dep -> | |
def node = new Node(deps, 'dependency') | |
new Node(node, 'groupId', dep.group) | |
new Node(node, 'artifactId', dep.name) | |
new Node(node, 'version', dep.version); | |
} | |
} |
// Original code | |
it('does something complex', function(done) { | |
async.waterfall( | |
[ | |
function setupSchema(cb) { | |
db.setupSchema(/*...*/, cb); | |
}, | |
function createTestUser(cb) { | |
db.createUser({ name: 'a user name' }, cb); | |
} |
Checklist for LBUser implementation in iOS and Android SDKs.
Basic auth worklow:
Advanced:
var f = function() { | |
throw new Error('oops'); | |
}; | |
f.displayName = 'myfunc'; | |
f(); |
var fs = require('fs'); | |
var net = require('net'); | |
var path = require('path'); | |
var loopback = require('loopback'); | |
var request = require('supertest'); | |
var http = require('http'); | |
var storageDir = path.join(__dirname, '_storage'); | |
if (!fs.existsSync(storageDir)) fs.mkdirSync(storageDir); |
var net = require('net'); | |
var extend = require('util')._extend; | |
var express = require('express'); | |
var RemoteObjects = require('strong-remoting'); | |
var objects = RemoteObjects.create(); | |
var reqUrl = givenStreamingEchoMethodWithAsyncSharedCtor(); | |
var app = express(); |
var loopback = require('loopback'); | |
var boot = require('loopback-boot'); | |
var app = module.exports = loopback(); | |
// hack sharedCtor | |
var setup = loopback.PersistedModel.setup; | |
loopback.PersistedModel.setup = function(rec) { | |
var extend = require('util')._extend; |
# output of `dtruss -p {pid}` for /System/Library/CoreServices/launchservicesd | |
SYSCALL(args) = return | |
workq_kernreturn(0x20, 0x0, 0x1) = 0 0 | |
process_policy(0x1, 0xF, 0x7) = 0 0 | |
process_policy(0x1, 0xF, 0x7) = 0 0 | |
kevent64(0x3, 0x7FFF72E3F130, 0x1) = 1 0 | |
workq_kernreturn(0x20, 0x0, 0x1) = 0 0 | |
kevent64(0x3, 0x7FFF72E3F130, 0x1) = 1 0 | |
workq_kernreturn(0x20, 0x0, 0x1) = 0 0 | |
process_policy(0x1, 0xF, 0x7) = 0 0 |