<commit_before>var vows = require('vows');
var assert = require("assert");

var Cropping = require("../lib/cropping");

vows.describe("General cropping calculations").addBatch({
    "when the aspect ration does not fit": {
        topic: function() {
            var cropping = new Cropping.CenteredCropping(1000, 500, 100, 100);
            return cropping.isNeeded();
        },
        "cropping is required": function(topic) {
            assert.equal(topic, true);
        }
    },
    "but when it fits": {
        topic: function() {
            var cropping = new Cropping.CenteredCropping(1000, 500, 300, 150);
            return cropping.isNeeded();
        },
        "no cropping is needed": function(topic) {
            assert.equal(topic, false);
        }
    }

}).export(module);<commit_msg>Typo fix<commit_after>var vows = require('vows');
var assert = require("assert");

var Cropping = require("../lib/cropping");

vows.describe("General cropping calculations").addBatch({
    "when the aspect ratio does not fit": {
        topic: function() {
            var cropping = new Cropping.CenteredCropping(1000, 500, 100, 100);
            return cropping.isNeeded();
        },
        "cropping is required": function(topic) {
            assert.equal(topic, true);
        }
    },
    "but when it fits": {
        topic: function() {
            var cropping = new Cropping.CenteredCropping(1000, 500, 300, 150);
            return cropping.isNeeded();
        },
        "no cropping is needed": function(topic) {
            assert.equal(topic, false);
        }
    }
}).export(module);
{'fraction_non_alphanumeric': 0.13656114214773432, 'fraction_numerical': 0.03227808814400993, 'mean_word_length': 2.3100616016427105, 'pattern_counts': {'":': 8, '<': 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': '2817309', 'n_tokens_mistral': 511, 'n_tokens_neox': 455, 'n_words': 118}