<commit_before>var Twitter = require('../index'),
    config = require('./config.json'),
    should = require('should');

describe('Twitter.Timelines Functions:', function() {
  describe('Timelines loading', function() {
    it('should create the Object', function() {
      var timelines = new Twitter.Timelines(config);

      timelines.should.be.an.instanceOf(Object);
    });
  });

  describe('Timelines.mentions()', function() {
    it('should be implemented, not yet', function() {
      console.log('TODO: TO BE IMPLEMENTED!');
    });
  });

  describe('Timelines.user()', function() {
    it('should request an user timeline', function(done) {
      var timelines = new Twitter.Timelines(config),
          params = {
            screen_name: 'ghostbar',
            count: 1
          };

      timelines.user(params, function(err, response) {
        should.not.exist(err);

        should.exist(response);

        done();
      });
    });
  });

  describe('Timelines.home()', function() {
    it('should be implemented, not yet', function() {
      console.log('TODO: TO BE IMPLEMENTED!');
    });
  });

  describe('Timelines.retweets()', function() {
    it('should be implemented, not yet', function() {
      console.log('TODO: TO BE IMPLEMENTED!');
    });
  });
});
<commit_msg>test-timelines: updated<commit_after>/* global describe */
/* global it */
'use strict';

var Twitter = require('../index');
var optional = require('optional');
var optConfig = {consumer_key: 'random', consumer_secret: 'random', token: 'random', token_secret: 'random'};
var config = optional('./config.json') || optConfig;
var should = require('should');

describe('Twitter.Timelines Functions:', function () {

  describe('Timelines loading', function () {
    it('should create the Object', function () {
      var timelines = new Twitter.Timelines(config);

      should.exist(timelines.Timelines);

      timelines.should.be.an.instanceOf(Object);
    });
  });

  describe('Timelines.user()', function () {
    it('should return an error for missing screen_name', function (done) {
      var timelines = new Twitter.Timelines(config);
      var params = { count: 1 };

      timelines.user(params, function (err) {
        should.exist(err);

        done();
      });
    });
  });

});

{'fraction_non_alphanumeric': 0.17044463818657368, 'fraction_numerical': 0.0008718395815170009, 'mean_word_length': 3.187956204379562, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1644039', 'n_tokens_mistral': 678, 'n_tokens_neox': 656, 'n_words': 154}