<commit_before>/*global jasmine,describe,expect,beforeEach,spyOn,it,Person,setName,getName,window,setFixtures,getJSONFixture,sandbox,toBeInDOM*/
describe('Jasmine basic testing', function () {
  // custom spies
  describe("my own spies", function () {
    var name = 'Joe';

    beforeEach(function () {
      // spy setup
      spyOn(Person, 'setName').and.callThrough();
      // app call
      Person.setName(name);
    });

    it("should objects and methods be defined", function () {
      expect(Person).toBeDefined();
      expect(Person.name).toBeDefined();
      expect(Person.setName).toBeDefined();
      expect(Person.getName).toBeDefined();
    });

    it("should track that the spy was called with arguments", function () {
      expect(Person.setName).toHaveBeenCalledWith(name);
    });

    it("should track that return the expected name", function () {
      expect(Person.getName()).toEqual(name);
    });
  });

  describe('jasmine-jquery testing', function () {
    var $ = null;
    beforeEach(function () {
      $ = $j;
    });
    afterEach(function () {
      $ = null;
    });
    describe('dom testing', function () {
      beforeEach(function () {
        setFixtures(sandbox());
      });
      it('should find sandbox elem in DOM', function () {
        expect($('#sandbox')).toBeInDOM();
      });
    });

    xdescribe('json fixtures testing', function () {
      var data, expectedDataLength;
      beforeEach(function () {
        jasmine.getJSONFixtures().fixturesPath = '/spec/fixtures/json';
        expectedDataLength = 3;
      });
      it('should load points data from json fixtures', function () {
        data = getJSONFixture('points.json');
        expect(data.points.length).toBe(expectedDataLength);
      });
    });
  });
});<commit_msg>adding globals to past jslint<commit_after>/*global jasmine,describe,xdescribe,expect,beforeEach,afterEach,spyOn,it,Person,
setName,getName,window,setFixtures,getJSONFixture,sandbox,toBeInDOM, $j*/
describe('Jasmine basic testing', function () {
  // custom spies
  describe("my own spies", function () {
    var name = 'Joe';

    beforeEach(function () {
      // spy setup
      spyOn(Person, 'setName').and.callThrough();
      // app call
      Person.setName(name);
    });

    it("should objects and methods be defined", function () {
      expect(Person).toBeDefined();
      expect(Person.name).toBeDefined();
      expect(Person.setName).toBeDefined();
      expect(Person.getName).toBeDefined();
    });

    it("should track that the spy was called with arguments", function () {
      expect(Person.setName).toHaveBeenCalledWith(name);
    });

    it("should track that return the expected name", function () {
      expect(Person.getName()).toEqual(name);
    });
  });

  describe('jasmine-jquery testing', function () {
    var $ = null;
    beforeEach(function () {
      $ = $j;
    });
    afterEach(function () {
      $ = null;
    });
    describe('dom testing', function () {
      beforeEach(function () {
        setFixtures(sandbox());
      });
      it('should find sandbox elem in DOM', function () {
        expect($('#sandbox')).toBeInDOM();
      });
    });

    xdescribe('json fixtures testing', function () {
      var data, expectedDataLength;
      beforeEach(function () {
        jasmine.getJSONFixtures().fixturesPath = '/spec/fixtures/json';
        expectedDataLength = 3;
      });
      it('should load points data from json fixtures', function () {
        data = getJSONFixture('points.json');
        expect(data.points.length).toBe(expectedDataLength);
      });
    });
  });
});
{'fraction_non_alphanumeric': 0.15575807787903895, 'fraction_numerical': 0.0005523336095001381, 'mean_word_length': 2.9845984598459845, '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': '6048313', 'n_tokens_mistral': 1067, 'n_tokens_neox': 1027, 'n_words': 204}