<commit_before>'use strict';

var assert = require('assert'),
    headersHelper = require('../../../src/models/http/headersHelper');

describe.only('headersHelper', function () {
    describe('#getJar', function () {
        describe('#get', function () {
            it('should search for the header with case-insensity', function () {
                var request = {
                        headers: {
                            'My-First-header': 'first-value',
                            'my-Second-Header': 'second-value'
                        }
                    },
                    headersJar = headersHelper.getJar(request.headers);

                assert.equal(headersJar.get('my-first-headEr'), 'first-value');
                assert.equal(headersJar.get('my-SECOND-header'), 'second-value');
            });

            it('should return undefined if the header is not present', function () {
                var request = {
                        headers: {
                            'My-First-header': 'first-value',
                            'my-Second-Header': 'second-value'
                        }
                    },
                    headersJar = headersHelper.getJar(request.headers);

                assert.equal(headersJar.get('Missing-Header'), undefined);
            });
        });

        describe('#set', function () {
            it('should not change the casing if the header exists', function () {<commit_msg>Removed .only() call for tests accidentally left<commit_after>'use strict';

var assert = require('assert'),
    headersHelper = require('../../../src/models/http/headersHelper');

describe('headersHelper', function () {
    describe('#getJar', function () {
        describe('#get', function () {
            it('should search for the header with case-insensity', function () {
                var request = {
                        headers: {
                            'My-First-header': 'first-value',
                            'my-Second-Header': 'second-value'
                        }
                    },
                    headersJar = headersHelper.getJar(request.headers);

                assert.equal(headersJar.get('my-first-headEr'), 'first-value');
                assert.equal(headersJar.get('my-SECOND-header'), 'second-value');
            });

            it('should return undefined if the header is not present', function () {
                var request = {
                        headers: {
                            'My-First-header': 'first-value',
                            'my-Second-Header': 'second-value'
                        }
                    },
                    headersJar = headersHelper.getJar(request.headers);

                assert.equal(headersJar.get('Missing-Header'), undefined);
            });
        });

        describe('#set', function () {
            it('should not change the casing if the header exists', function () {
{'fraction_non_alphanumeric': 0.13175675675675674, 'fraction_numerical': 0.0, 'mean_word_length': 1.4290401968826907, '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': '6329306', 'n_tokens_mistral': 714, 'n_tokens_neox': 677, 'n_words': 140}