Fix unit test

This commit is contained in:
2024-10-11 15:09:01 +02:00
parent 2d488a75eb
commit 8cfe93f096
3 changed files with 4 additions and 3 deletions

View File

@@ -7,7 +7,7 @@ on:
- master
jobs:
build-and-deploy:
build-test:
runs-on: ubuntu-latest
environment: production

View File

@@ -1,10 +1,11 @@
// cypress/integration/app_spec.js
describe('App Component', () => {
beforeEach(() => {
cy.visit('/');
});
it('renders the app and checks if CSS is loaded', () => {
cy.get('[data-testid="root"]').should('exist');
cy.get('[data-testid="root"]', { timeout: 10000 }).should('exist');
cy.get('[data-testid="root"]').should('have.class', 'min-h-screen py-10 px-3 sm:px-5 bg-gray-100 dark:bg-gray-900');
});
});

View File

@@ -39,7 +39,7 @@ function App() {
}
return (
<div className="min-h-screen py-10 px-3 sm:px-5 bg-gray-100 dark:bg-gray-900">
<div className="min-h-screen py-10 px-3 sm:px-5 bg-gray-100 dark:bg-gray-900" data-testid="root">
<Menu />
<div data-aos="face-down" data-aos-duration="800" id="top">
<Card name={data.name} title={data.title} social={data.social} />