'use strict';

describe('PIXI.Graphics', () =>
{
    describe('constructor', () =>
    {
        it('should set defaults', () =>
        {
            const graphics = new PIXI.Graphics();

            expect(graphics.fillAlpha).to.be.equals(1);
            expect(graphics.lineWidth).to.be.equals(0);
            expect(graphics.lineColor).to.be.equals(0);
            expect(graphics.tint).to.be.equals(0xFFFFFF);
            expect(graphics.blendMode).to.be.equals(PIXI.BLEND_MODES.NORMAL);
        });
    });

    describe('lineTo', () =>
    {
        it('should return the correct bounds', () =>
        {
            const graphics = new PIXI.Graphics();

            graphics.moveTo(0, 0);
            graphics.lineStyle(1);
            graphics.lineTo(0, 10);

            expect(graphics.width).to.be.equals(1);
            expect(graphics.height).to.be.equals(10);
        });
    });
});

@@ -573,12 +573,8 @@
 urn 
-the 
 corr
@@ -583,16 +583,24 @@
 t bounds
+ - north
 ', () =%3E
@@ -813,69 +813,2359 @@
 .be.
-equals(1);%0A            expect(graphics.height).to.be.equals(1
+below(1.00001);%0A            expect(graphics.width).to.be.above(0.99999);%0A            expect(graphics.height).to.be.equals(10);%0A        %7D);%0A%0A        it('should return correct bounds - south', () =%3E%0A        %7B%0A            const graphics = new PIXI.Graphics();%0A%0A            graphics.moveTo(0, 0);%0A            graphics.lineStyle(1);%0A            graphics.lineTo(0, -10);%0A%0A            expect(graphics.width).to.be.below(1.00001);%0A            expect(graphics.width).to.be.above(0.99999);%0A            expect(graphics.height).to.be.equals(10);%0A        %7D);%0A%0A        it('should return correct bounds - east', () =%3E%0A        %7B%0A            const graphics = new PIXI.Graphics();%0A%0A            graphics.moveTo(0, 0);%0A            graphics.lineStyle(1);%0A            graphics.lineTo(10, 0);%0A%0A            expect(graphics.height).to.be.equals(1);%0A            expect(graphics.width).to.be.equals(10);%0A        %7D);%0A%0A        it('should return correct bounds - west', () =%3E%0A        %7B%0A            const graphics = new PIXI.Graphics();%0A%0A            graphics.moveTo(0, 0);%0A            graphics.lineStyle(1);%0A            graphics.lineTo(-10, 0);%0A%0A            expect(graphics.height).to.be.above(0.9999);%0A            expect(graphics.height).to.be.below(1.0001);%0A            expect(graphics.width).to.be.equals(10);%0A        %7D);%0A%0A        it('should return correct bounds when stacked with circle', () =%3E%0A        %7B%0A            const graphics = new PIXI.Graphics();%0A%0A            graphics.beginFill(0xFF0000);%0A            graphics.drawCircle(50, 50, 50);%0A            graphics.endFill();%0A%0A            expect(graphics.width).to.be.equals(100);%0A            expect(graphics.height).to.be.equals(100);%0A%0A            graphics.lineStyle(20, 0);%0A            graphics.moveTo(25, 50);%0A            graphics.lineTo(75, 50);%0A%0A            expect(graphics.width).to.be.equals(100);%0A            expect(graphics.height).to.be.equals(100);%0A        %7D);%0A%0A        it('should return correct bounds when square', () =%3E%0A        %7B%0A            const graphics = new PIXI.Graphics();%0A%0A            graphics.lineStyle(20, 0, 0.5);%0A            graphics.moveTo(10, 10);%0A            graphics.lineTo(50, 10);%0A            graphics.lineTo(50, 50);%0A            graphics.lineTo(10, 50);%0A            graphics.lineTo(10, 10);%0A%0A            expect(graphics.width).to.be.equals(50);%0A            expect(graphics.height).to.be.equals(5
 0);%0A

extend Graphics.lineTo expectations