mirror of
https://github.com/amark/gun.git
synced 2025-06-10 16:16:49 +00:00
keys
This commit is contained in:
parent
370fcd7d8b
commit
509c1d5cfd
@ -4,20 +4,12 @@ module.exports=require('theory')
|
||||
, invincible: true
|
||||
, dep: ['../shots']
|
||||
, init: function(a){
|
||||
console.log("ECHO");
|
||||
var echo = {}, redis, client;
|
||||
echo.shot = a.shots();
|
||||
echo.put = function(m){
|
||||
console.log('stream', m);
|
||||
}
|
||||
echo.state = function(m){
|
||||
redis = redis || require('redis')
|
||||
, client = client || redis.createClient();
|
||||
client.set("string key", "string val", redis.print);
|
||||
client.get("string key", function(e,r){
|
||||
console.log("WE DID IT!!!!");
|
||||
console.log(e, r);
|
||||
});
|
||||
if(echo.shot.server(m,a.com.reply)){ return }
|
||||
m.what.body = '';
|
||||
a.com.reply(m);
|
||||
|
@ -1,7 +1,6 @@
|
||||
module.exports=require('theory')
|
||||
('tests',function(a){
|
||||
if(root.node){
|
||||
require('../../../lushly/keys');
|
||||
var shot = require('../shots')({src: a.com}).pump(function(g, m, done){
|
||||
done();
|
||||
});
|
||||
@ -93,7 +92,7 @@ module.exports=require('theory')
|
||||
it('tests',function(){
|
||||
//return;
|
||||
//var s = theory.shot({src: '/test/server.js'})
|
||||
var s = shot.shell('lushly.org/tests/package.json',function(g){
|
||||
var s = shot.shell('gunjs.herokuapp.com/tests/package.json',function(g){
|
||||
if(!g){ return }
|
||||
console.log('graph', g());
|
||||
var p = g('packageson');
|
||||
@ -103,7 +102,7 @@ module.exports=require('theory')
|
||||
console.log(val);
|
||||
p('version',val);
|
||||
a.time.wait(function(){
|
||||
shot.shell('lushly.org/tests/package.json',function(gg){
|
||||
shot.shell('gunjs.herokuapp.com/tests/package.json',function(gg){
|
||||
var pp = gg('packageson');
|
||||
console.log('graph prime', gg());
|
||||
expect(val).to.be(pp('version'));
|
||||
|
Loading…
x
Reference in New Issue
Block a user