<commit_before>'use strict';
var test = require('tape');
var shortNumber = require('./');

test('positive tests', function(t) {
    t.plan(11);

    t.equal(shortNumber(231), 231);
    t.equal(shortNumber(5432), '5.4K');
    t.equal(shortNumber(35656), '35.7K');
    t.equal(shortNumber(1236903), '1.2M');
    t.equal(shortNumber(49653234), '49.7M');
    t.equal(shortNumber(984938293), '984.9M');
    t.equal(shortNumber(2743000000), '2.7B');
    t.equal(shortNumber(64743000000), '64.7B');
    t.equal(shortNumber(344843000000), '344.8B');
    t.equal(shortNumber(1344843000000), '1.3T');
});

test('negative tests', function(t) {
    t.plan(11);

    t.equal(shortNumber(-231), -231);
    t.equal(shortNumber(-5432), '-5.4K');
    t.equal(shortNumber(-35656), '-35.7K');
    t.equal(shortNumber(-1236903), '-1.2M');
    t.equal(shortNumber(-49653234), '-49.7M');
    t.equal(shortNumber(-984938293), '-984.9M');
    t.equal(shortNumber(-2743000000), '-2.7B');
    t.equal(shortNumber(-64743000000), '-64.7B');
    t.equal(shortNumber(-344843000000), '-344.8B');<commit_msg>Fixes unit test.<commit_after>'use strict';
var test = require('tape');
var shortNumber = require('./');

test('positive tests', function(t) {
    t.plan(11);

    t.equal(shortNumber(231), 231);
    t.equal(shortNumber(1000), '1K');
    t.equal(shortNumber(5432), '5.4K');
    t.equal(shortNumber(35656), '35.7K');
    t.equal(shortNumber(1236903), '1.2M');
    t.equal(shortNumber(49653234), '49.7M');
    t.equal(shortNumber(984938293), '984.9M');
    t.equal(shortNumber(2743000000), '2.7B');
    t.equal(shortNumber(64743000000), '64.7B');
    t.equal(shortNumber(344843000000), '344.8B');
    t.equal(shortNumber(1344843000000), '1.3T');
});

test('negative tests', function(t) {
    t.plan(11);

    t.equal(shortNumber(-231), -231);
    t.equal(shortNumber(-1000), '-1K');
    t.equal(shortNumber(-5432), '-5.4K');
    t.equal(shortNumber(-35656), '-35.7K');
    t.equal(shortNumber(-1236903), '-1.2M');
    t.equal(shortNumber(-49653234), '-49.7M');
    t.equal(shortNumber(-984938293), '-984.9M');
    t.equal(shortNumber(-2743000000), '-2.7B');
    t.equal(shortNumber(-64743000000), '-64.7B');
    t.equal(shortNumber(-344843000000), '-344.8B');
{'fraction_non_alphanumeric': 0.23063143752798926, 'fraction_numerical': 0.19167039856695028, 'mean_word_length': 4.219626168224299, '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': '2686478', 'n_tokens_mistral': 1124, 'n_tokens_neox': 883, 'n_words': 113}