       it 'should return values between -1 and 1', ->
         for i in [0..10]
           for j in [0..10]
-            expect(noise(i / 5, j / 5, i + j, i - j)).to.be.above(-1).and.below(1)
+            expect(noise(i / 5, j / 5, i + j, i - j)).to.be.within(-1, 1)
 
       it 'should return similar values for similar inputs', ->
         expect(Math.abs(noise(0.1, 0.2, 0.3, 0.4) - noise(0.101, 0.201, 0.301, 0.401))).to.be.below(0.1).and.above(0)


      it 'should return values between -1 and 1', ->
        for x in [0..10]
          expect(noise(x)).to.be.above(-1).and.below(1)

      it 'should return similar values for similar inputs', ->
        expect(Math.abs(noise(0.1) - noise(0.101))).to.be.below(0.1).and.above(0)

      it 'should return values between -1 and 1', ->
        for x in [0..10]
          for y in [0..10]
            expect(noise(x, y)).to.be.within(-1, 1)

      it 'should return similar values for similar inputs', ->
        expect(Math.abs(noise(0.1, 0.2) - noise(0.101, 0.201))).to.be.below(0.1).and.above(0)
