
/////////////////////////
// Helpers and globals //
/////////////////////////

const expect = chai.expect;

////////////////
// Test suite //
////////////////

describe('Rainbow', function() {
    it('Basic things are defined', () => {
        expect(Rainbow).to.exist;
        expect(Rainbow.color).to.be.a('function');
        expect(Rainbow.extend).to.be.a('function');
        expect(Rainbow.onHighlight).to.be.a('function');
        expect(Rainbow.addClass).to.be.a('function');
        expect(Rainbow.addAlias).to.be.a('function');
    });
});

@@ -1,28 +1,49 @@
+/* global Rainbow */%0A
 %0A/////////////////////////%0A/
@@ -199,18 +199,13 @@
 w', 
-function()
+() =%3E
  %7B%0A 
@@ -486,32 +486,32 @@
 .a('function');%0A
-
         expect(R
@@ -555,13 +555,398 @@
 %0A    %7D);
+%0A%0A    it('Should apply global class', (done) =%3E %7B%0A        Rainbow.extend(%5B%7B%0A            name: 'name',%0A            pattern: /Craig/gm%0A        %7D%5D);%0A%0A        Rainbow.addClass('global');%0A%0A        Rainbow.color('My name is Craig', 'generic', function(result) %7B%0A            expect(result).to.equal('My name is %3Cspan class=%22name global%22%3ECraig%3C/span%3E');%0A            done();%0A        %7D);%0A    %7D);
 %0A%7D);%0A

Add unit test for applying global class