<commit_before>var Datify = require('./');

var Lab = require('lab');
var Chai = require('chai');

Chai.should();
var it = Lab.test;

Lab.experiment('datify', function(){
	it('should convert an ISO Date string to the right date', function(done){
		Datify('2011-09-13T17:09:30.909Z').should.eql(new Date('2011-09-13T17:09:30.909Z'));
		Datify('2011-09-13T17:09:30.909Z').toISOString().should.eql('2011-09-13T17:09:30.909Z');
		done();
	}),

	it('should keep the "a message" unchanged', function(done){
		Datify('a message').should.eql("a message");
		done();
	}),

	it('should convert an object with an ISO date string to an object with Date', function(done){
		var anObject = {
			content: { },
			createdAt: '2011-09-13T17:12:30.909Z'
		}
		Datify(anObject).should.eql({
			content: { },
			createdAt: new Date('2011-09-13T17:12:30.909Z')
		});

		done();
	}),

	it('should return a different object then the one it was converting', function(done){
		var anObject = {
			content: { },
			createdAt: '2011-09-13T17:12:30.909Z'
		}
		Datify(anObject).should.not.equal(anObject);

		done();
	}),
<commit_msg>make sure Date is unchanged<commit_after>var Datify = require('./');

var Lab = require('lab');
var Chai = require('chai');

Chai.should();
var it = Lab.test;

Lab.experiment('datify', function(){
	it('should convert an ISO Date string to the right date', function(done){
		Datify('2011-09-13T17:09:30.909Z').should.eql(new Date('2011-09-13T17:09:30.909Z'));
		Datify('2011-09-13T17:09:30.909Z').toISOString().should.eql('2011-09-13T17:09:30.909Z');
		done();
	}),

	it('should keep the "a message" unchanged', function(done){
		Datify('a message').should.eql("a message");
		done();
	}),

	it('should keep a js Date unchanged', function(done){
		Datify(new Date('2011-09-13T17:09:30.909Z')).should.eql(new Date('2011-09-13T17:09:30.909Z'));
		Datify(new Date('2011-09-13T17:09:30.909Z')).toISOString().should.eql('2011-09-13T17:09:30.909Z');
		done();
	}),

	it('should convert an object with an ISO date string to an object with Date', function(done){
		var anObject = {
			content: { },
			createdAt: '2011-09-13T17:12:30.909Z'
		}
		Datify(anObject).should.eql({
			content: { },
			createdAt: new Date('2011-09-13T17:12:30.909Z')
		});

		done();
	}),

	it('should return a different object then the one it was converting', function(done){
		var anObject = {
			content: { },
			createdAt: '2011-09-13T17:12:30.909Z'
		}
		Datify(anObject).should.not.equal(anObject);

		done();
	}),

{'fraction_non_alphanumeric': 0.19478957915831663, 'fraction_numerical': 0.12264529058116233, 'mean_word_length': 4.437908496732026, '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': '26759', 'n_tokens_mistral': 1190, 'n_tokens_neox': 937, 'n_words': 189}