Skip to content

Commit 1cdd1c4

Browse files
committed
ci: move to GH actions and npm
1 parent 077ecb5 commit 1cdd1c4

File tree

7 files changed

+65
-14113
lines changed

7 files changed

+65
-14113
lines changed

.circleci/config.yml

Lines changed: 0 additions & 112 deletions
This file was deleted.

.github/workflows/ci.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
name: ci
2+
3+
on: pull_request
4+
5+
jobs:
6+
build_and_test:
7+
runs-on: ubuntu-latest
8+
strategy:
9+
matrix:
10+
node-version: [12.x]
11+
12+
steps:
13+
- uses: actions/checkout@v1
14+
- name: use Node.js ${{ matrix.node-version }}
15+
uses: actions/setup-node@v1
16+
with:
17+
node-version: ${{ matrix.node-version }}
18+
- name: install
19+
run: npm install
20+
- name: lint
21+
run: npm run affected:lint
22+
- name: build
23+
run: npm run build --skip-nx-cache
24+
- name: test
25+
run: npm run affected:test --ci --code-coverage

.github/workflows/release.yml

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
name: release
2+
3+
on:
4+
push:
5+
branches:
6+
- master
7+
8+
jobs:
9+
release:
10+
if: github.repository == 'testing-library/angular-testing-library'
11+
runs-on: ubuntu-latest
12+
strategy:
13+
matrix:
14+
node-version: [12.x]
15+
16+
steps:
17+
- uses: actions/checkout@v1
18+
- name: use Node.js ${{ matrix.node-version }}
19+
uses: actions/setup-node@v1
20+
with:
21+
node-version: ${{ matrix.node-version }}
22+
- name: install
23+
run: npm install
24+
- name: lint
25+
run: npm run affected:lint
26+
- name: build
27+
run: npm run build --skip-nx-cache
28+
- name: test
29+
run: npm run affected:test --ci --code-coverage
30+
- name: Release
31+
env:
32+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
33+
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
34+
run: npx semantic-release

.npmrc

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
1-
registry=http://registry.npmjs.org/
1+
registry=http://registry.npmjs.org/
2+
package-lock=false

apps/example-app/app/examples/13-scrolling.component.spec.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
import { render, screen, waitForElementToBeRemoved } from '@testing-library/angular';
22

3-
import { CdkVirtualScrollOverviewExample } from './13-scrolling.component';
3+
import { CdkVirtualScrollOverviewExampleComponent } from './13-scrolling.component';
44
import { ScrollingModule } from '@angular/cdk/scrolling';
55

66
test('should scroll to load more items', async () => {
7-
await render(CdkVirtualScrollOverviewExample, {
7+
await render(CdkVirtualScrollOverviewExampleComponent, {
88
imports: [ScrollingModule],
99
});
1010

apps/example-app/app/examples/13-scrolling.component.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { ChangeDetectionStrategy, Component } from '@angular/core';
22

33
@Component({
4-
selector: 'cdk-virtual-scroll-overview-example',
4+
selector: 'app-cdk-virtual-scroll-overview-example',
55
template: `
66
<cdk-virtual-scroll-viewport itemSize="50" class="example-viewport" data-testid="scroll-viewport">
77
<div *cdkVirtualFor="let item of items" class="example-item">{{ item }}</div>
@@ -22,6 +22,6 @@ import { ChangeDetectionStrategy, Component } from '@angular/core';
2222
],
2323
changeDetection: ChangeDetectionStrategy.OnPush,
2424
})
25-
export class CdkVirtualScrollOverviewExample {
25+
export class CdkVirtualScrollOverviewExampleComponent {
2626
items = Array.from({ length: 100 }).map((_, i) => `Item #${i}`);
2727
}

0 commit comments

Comments
 (0)