Skip to content

Commit a76b16f

Browse files
fix tests
1 parent 7dbe599 commit a76b16f

File tree

2 files changed

+15
-2
lines changed

2 files changed

+15
-2
lines changed

.github/test.yml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
name: Test
2+
on: [pull_request]
3+
jobs:
4+
test:
5+
runs-on: ubuntu-latest
6+
steps:
7+
- uses: actions/checkout@v4
8+
- name: Use Node.js
9+
uses: actions/setup-node@v4
10+
with:
11+
node-version: "20.x"
12+
- run: npm install
13+
- run: npm test

src/app/app.component.spec.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,8 @@ describe("AppComponent", () => {
2424
const fixture = TestBed.createComponent(AppComponent);
2525
fixture.detectChanges();
2626
const compiled = fixture.nativeElement as HTMLElement;
27-
expect(compiled.querySelector("h1")?.textContent).toContain(
28-
"Hello, slacker-news",
27+
expect(compiled.querySelector("#title-text")?.textContent).toContain(
28+
"Slacker News",
2929
);
3030
});
3131
});

0 commit comments

Comments
 (0)