diff --git a/.github/workflows/run-tests.yml b/.github/workflows/run-tests.yml new file mode 100644 index 0000000..a924752 --- /dev/null +++ b/.github/workflows/run-tests.yml @@ -0,0 +1,27 @@ +name: Node.js CI + +on: + push: + branches: [ master ] + pull_request: + branches: [ master ] + +jobs: + build: + + runs-on: ubuntu-latest + + strategy: + matrix: + node-version: [14.x] + + steps: + - uses: actions/checkout@v2 + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v1 + with: + node-version: ${{ matrix.node-version }} + - run: npm ci + - run: npm run doc + - run: npm run build + - run: npm test diff --git a/docs/README.md b/docs/README.md index 2124baa..e3c6c0a 100644 --- a/docs/README.md +++ b/docs/README.md @@ -22,7 +22,7 @@ ▸ `Const`**computeShadows**(`bounds`: [Bounds](interfaces/bounds.md), `walls`: [Segment2](interfaces/segment2.md)[], `light`: [Vec2](interfaces/vec2.md)): [Vec2](interfaces/vec2.md)[][] -*Defined in [computeShadows.ts:39](https://github.com/MD4/shadowed/blob/3f8192d/src/computeShadows.ts#L39)* +*Defined in [computeShadows.ts:39](https://github.com/MD4/shadowed/blob/3438083/src/computeShadows.ts#L39)* Computes casted shadows by a light for a given set of walls within specified bounds. diff --git a/docs/interfaces/bounds.md b/docs/interfaces/bounds.md index 76fae23..2971ea4 100644 --- a/docs/interfaces/bounds.md +++ b/docs/interfaces/bounds.md @@ -21,7 +21,7 @@ • **bottomRight**: [Vec2](vec2.md) -*Defined in [entities.ts:8](https://github.com/MD4/shadowed/blob/3f8192d/src/entities.ts#L8)* +*Defined in [entities.ts:8](https://github.com/MD4/shadowed/blob/3438083/src/entities.ts#L8)* ___ @@ -29,4 +29,4 @@ ___ • **topLeft**: [Vec2](vec2.md) -*Defined in [entities.ts:7](https://github.com/MD4/shadowed/blob/3f8192d/src/entities.ts#L7)* +*Defined in [entities.ts:7](https://github.com/MD4/shadowed/blob/3438083/src/entities.ts#L7)* diff --git a/docs/interfaces/segment2.md b/docs/interfaces/segment2.md index 46858af..fd84ede 100644 --- a/docs/interfaces/segment2.md +++ b/docs/interfaces/segment2.md @@ -21,7 +21,7 @@ • **a**: [Vec2](vec2.md) -*Defined in [entities.ts:12](https://github.com/MD4/shadowed/blob/3f8192d/src/entities.ts#L12)* +*Defined in [entities.ts:12](https://github.com/MD4/shadowed/blob/3438083/src/entities.ts#L12)* ___ @@ -29,4 +29,4 @@ ___ • **b**: [Vec2](vec2.md) -*Defined in [entities.ts:13](https://github.com/MD4/shadowed/blob/3f8192d/src/entities.ts#L13)* +*Defined in [entities.ts:13](https://github.com/MD4/shadowed/blob/3438083/src/entities.ts#L13)* diff --git a/docs/interfaces/vec2.md b/docs/interfaces/vec2.md index 86ae506..50451f0 100644 --- a/docs/interfaces/vec2.md +++ b/docs/interfaces/vec2.md @@ -21,7 +21,7 @@ • **x**: number -*Defined in [entities.ts:2](https://github.com/MD4/shadowed/blob/3f8192d/src/entities.ts#L2)* +*Defined in [entities.ts:2](https://github.com/MD4/shadowed/blob/3438083/src/entities.ts#L2)* ___ @@ -29,4 +29,4 @@ ___ • **y**: number -*Defined in [entities.ts:3](https://github.com/MD4/shadowed/blob/3f8192d/src/entities.ts#L3)* +*Defined in [entities.ts:3](https://github.com/MD4/shadowed/blob/3438083/src/entities.ts#L3)*