<commit_before>describe('SessionStore', function () {

  beforeEach(function (done) {
    window.sessionStorage.clear();
    done();
  });

  it('to set the namespace property', function() {
    var store = new SessionStore('sessionstore');

    expect(store).to.have.property('ns');
    expect(store.ns).to.equal('sessionstore');
  });

  it('to set data property', function () {
    var store = new SessionStore('sessionstore', { version: '1.0.0' });

    expect(store.data).to.be.a('object');
    expect(store.data).to.eql({ version: '1.0.0' })
  });

  it('to store data passed in as argument, in sessionStorage', function () {
    var store = new SessionStore('sessionstore', { version: '2.0.0' });

    expect(JSON.parse(sessionStorage.getItem('sessionstore'))).to.eql({ version: '2.0.0' });
  });

  it('to store data set as value in sessionStorage', function () {
    var store = new SessionStore('sessionstore');

    store.data = { test: '1234' };

    expect(JSON.parse(sessionStorage.getItem('sessionstore'))).to.eql({ test: '1234' });
  });

  it('to not overwrite data in sessionStorage', function () {
    window.sessionStorage.setItem('sessionstore', '{ "test": 123 }');
    var store = new SessionStore('sessionstore');

    expect(JSON.parse(sessionStorage.getItem('sessionstore'))).to.eql({ test: 123 });
  });

  it('retrives the individual property from data', function () {
    var store = new SessionStore('testing', { storage: ['session', 'local'] });

    expect(store.getItem('storage')).to.eql(['session', 'local']);
  });

  it('sets the individual property to data', function () {
    var store = new SessionStore('testing', { storage: ['session', 'local'] });

    store.setItem('storage', 'IndexedDB');

    expect(store.getItem('storage')).to.eql('IndexedDB');
  });

  it('data should be unique among instances', function () {
    var store1 =  new SessionStore('sessionstore', { version: '1.0.0' });
    var store2 =  new SessionStore('sessionstore', { version: '2.0.0' });

    expect(store1.data).to.not.eql(store2.data);
  })
});<commit_msg>fixed specs<commit_after>describe('SessionStore', function () {

  beforeEach(function (done) {
    window.sessionStorage.clear();
    done();
  });

  it('to set the namespace property', function() {
    var store = new SessionStore('sessionstore');

    expect(store).to.have.property('ns');
    expect(store.ns).to.equal('sessionstore');
  });

  it('to set data property', function () {
    var store = new SessionStore('sessionstore', { version: '1.0.0' });

    expect(store.data).to.be.a('object');
    expect(store.data).to.eql({ version: '1.0.0' })
  });

  it('to store data passed in as argument, in sessionStorage', function () {
    var store = new SessionStore('sessionstore', { version: '2.0.0' });

    expect(JSON.parse(sessionStorage.getItem('sessionstore'))).to.eql({ version: '2.0.0' });
  });

  it('to store data set as value in sessionStorage', function () {
    var store = new SessionStore('sessionstore');

    store.data = { test: '1234' };

    expect(JSON.parse(sessionStorage.getItem('sessionstore'))).to.eql({ test: '1234' });
  });

  it('to not overwrite data in sessionStorage', function () {
    window.sessionStorage.setItem('sessionstore', '{ "test": 123 }');
    var store = new SessionStore('sessionstore');

    expect(JSON.parse(sessionStorage.getItem('sessionstore'))).to.eql({ test: 123 });
  });

  it('retrives the individual property from data', function () {
    var store = new SessionStore('testing', { storage: ['session', 'local'] });

    expect(store.getItem('storage')).to.eql(['session', 'local']);
  });

  it('sets the individual property to data', function () {
    var store = new SessionStore('testing', { storage: ['session', 'local'] });

    store.setItem('storage', 'IndexedDB');

    expect(store.getItem('storage')).to.eql('IndexedDB');
  });

  it('data should be identical among instances using the same namespace', function () {
    var store1 =  new SessionStore('sessionstore', { version: '1.0.0' });
    var store2 =  new SessionStore('sessionstore', { version: '2.0.0' });

    expect(store1.data).to.eql(store2.data);
  })

  it('data should be unique among instances with different namespace', function () {
    var store1 =  new SessionStore('sessionstore', { version: '1.0.0' });
    var store2 =  new SessionStore('sessionstore2', { version: '2.0.0' });

    expect(store1.data).to.not.eql(store2.data);
  });
});
{'fraction_non_alphanumeric': 0.1877377489371224, 'fraction_numerical': 0.018572387558737972, 'mean_word_length': 4.102739726027397, 'pattern_counts': {'":': 2, '<': 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': '2730965', 'n_tokens_mistral': 1411, 'n_tokens_neox': 1353, 'n_words': 310}