<commit_before>/*eslint max-nested-callbacks: 0, no-unused-expressions: 0 */
'use strict';
// assertion library
// /////////////////////////////////////////////////////////
var chai = require('chai');
var sinon = require('sinon');
var sinonChai = require('sinon-chai');
chai.should();
chai.use(sinonChai);

// mock data
let mockReq = {
  'originalIp': '1313'
};

// modules to test
// /////////////////////////////////////////////////////////
let privates = require('../../lib/privates');


describe('Privates', function () {
  describe('#handleRequest', function () {
    it('should return .originalIp of passed request', function (){
      let ip = privates.handleRequest(mockReq.originalIp);
      ip.should.be(mockReq.originalIp);
    });
  });

  describe('#noop', function () {
    it('should be a function', function () {
      privates.noop.should.be.a.function;
    })

    it('should not return anything when called', function (){
      let val = privates.noop();
      val.should.be.undefined;
    });
  });
});<commit_msg>fixed tets for privates.js<commit_after>/*eslint max-nested-callbacks: 0, no-unused-expressions: 0 */
'use strict';
// assertion library
// /////////////////////////////////////////////////////////
var chai = require('chai');
var sinon = require('sinon');
var sinonChai = require('sinon-chai');
chai.should();
chai.use(sinonChai);

// mock data
let mockReq = {
  'originalUrl': '1313'
};

// modules to test
// /////////////////////////////////////////////////////////
let privates = require('../../lib/privates');

describe('Privates', function () {
  describe('#handleRequest', function () {
    it('should return .originalUrl of passed request', function (){
      let ip = privates.handleRequest(mockReq);
      ip.should.eql(mockReq.originalUrl);
    });
  });

  describe('#noop', function () {
    it('should be a function', function () {
      privates.noop.should.be.a.function;
    })

    it('should return undefined when called', function (){
      var val = typeof privates.noop();
      val.should.equal('undefined');
    });
  });
});
{'fraction_non_alphanumeric': 0.26932309169467117, 'fraction_numerical': 0.005760921747479597, 'mean_word_length': 2.2160493827160495, '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': '4121227', 'n_tokens_mistral': 613, 'n_tokens_neox': 591, 'n_words': 135}