Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*globals describe, beforeEach, it */
- var should = require('should'),
- mockery = require('mockery'),
- helpers = require('./helpers'),
- Cache = require('../chatter-cache').ChatterCache;
- describe('Chatter Cache', function() {
- var proxy = null;
- beforeEach(function(done) {
- helpers.fetchProxy(function(err, data) {
- if (err) return done(err);
- proxy = data;
- done();
- });
- });
- it('Can fetch users', function(done) {
- var cache = new Cache(proxy);
- cache.users(1, function(err, users) {
- if (err) return done(err);
- should.exist(users);
- users.should.have.property('length');
- done();
- });
- });
- it('Can fetch mentions..', function(done) {
- var cache = new Cache(proxy);
- cache.mentions(1, function(err, mentions) {
- if (err) return done(err);
- should.exist(mentions);
- mentions.should.have.property('length');
- done();
- });
- });
- });
Add Comment
Please, Sign In to add comment