-
-
Notifications
You must be signed in to change notification settings - Fork 632
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into footer_test
- Loading branch information
Showing
20 changed files
with
310 additions
and
128 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
import {goldSponsors} from './GoldSponsorsList'; | ||
export default function GoldSponsors({ className = '', showSupportBanner = true }) { | ||
return ( | ||
<div className={`text-center ${className}`}> | ||
<div className="flex flex-wrap mb-8 items-center justify-center md:px-4"> | ||
{goldSponsors.map((sponsor, index) => ( | ||
<a | ||
key={index} | ||
href={sponsor.website} | ||
target="_blank" | ||
className="block relative text-center w-2/3 px-4 py-4 sm:p-0 sm:w-1/2 md:w-1/3 lg:w-1/5" | ||
rel="noopener noreferrer" | ||
data-testid="GoldSponsors-link" | ||
> | ||
<img | ||
className="inline-block sm:h-12" | ||
src={sponsor.imageSrc} | ||
alt={sponsor.name} | ||
data-testid="GoldSponsors-img" | ||
/> | ||
</a> | ||
))} | ||
</div> | ||
</div> | ||
); | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
export const goldSponsors = [ | ||
{ | ||
name: 'Red Hat', | ||
imageSrc: '/img/sponsors/redhat.svg', | ||
website: 'https://www.redhat.com/', | ||
}, | ||
|
||
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
import { Silversponsors } from "./SilverSponsorsList"; | ||
export default function SilverSponsors({ className = '', showSupportBanner = true }) { | ||
return ( | ||
<div className={`text-center ${className}`}> | ||
<div className="flex flex-wrap mb-8 items-center justify-center md:px-4"> | ||
{Silversponsors.map((sponsor, index) => ( | ||
<a | ||
key={index} | ||
href={sponsor.url} | ||
target="_blank" | ||
className="block relative text-center w-2/3 px-4 py-4 sm:p-0 sm:w-1/2 md:w-1/3 lg:w-1/5" | ||
rel="noopener noreferrer" | ||
data-testid="SilverSponsors-link" | ||
> | ||
<img | ||
className="inline-block sm:h-9" | ||
src={sponsor.image} | ||
alt={sponsor.name} | ||
data-testid="SilverSponsors-img" | ||
/> | ||
</a> | ||
))} | ||
</div> | ||
</div> | ||
); | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
export const Silversponsors = [ | ||
{ | ||
name: 'Bump.sh', | ||
url: 'https://bump.sh/asyncapi?utm_source=asyncapi&utm_medium=referral&utm_campaign=sponsor', | ||
image: '/img/sponsors/bumpsh.svg' | ||
}, | ||
|
||
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
import { sponsors } from "./SponsorsList"; | ||
export default function Sponsors({ className = '', showSupportBanner = true }) { | ||
return ( | ||
<div className={`text-center ${className}`}> | ||
<ul className="flex flex-wrap mb-4 items-center justify-center md:px-4"> | ||
{sponsors.map((sponsor, index) => ( | ||
<li | ||
key={index} | ||
className="w-2/3 sm:w-1/4 md:w-1/3 lg:w-1/5" | ||
data-testid="Sponsors-list" | ||
> | ||
<a | ||
href={sponsor.link} | ||
target="_blank" | ||
className="block relative text-center px-4 py-4 sm:p-0" | ||
rel="noopener noreferrer" | ||
data-testid="Sponsors-link" | ||
> | ||
<img | ||
className={sponsor.imageClass} | ||
src={sponsor.imageSrc} | ||
alt={sponsor.altText} | ||
data-testid="Sponsors-img" | ||
/> | ||
</a> | ||
</li> | ||
))} | ||
</ul> | ||
{showSupportBanner && ( | ||
<div className="md:px-4"> | ||
<span className="text-gray-500">Want to become a sponsor?</span>{' '} | ||
<a | ||
href="https://opencollective.com/asyncapi" | ||
target="_blank" | ||
rel="noopener noreferrer" | ||
className="text-primary-600" | ||
> | ||
Support us! | ||
</a> | ||
</div> | ||
)} | ||
</div> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
export const sponsors = [ | ||
{ | ||
name: 'IBM', | ||
link: 'https://www.ibm.com', | ||
imageSrc: '/img/sponsors/ibm.png', | ||
altText: 'IBM', | ||
imageClass: 'inline-block px-4 sm:h-14', | ||
}, | ||
{ | ||
name: 'IQVIA Technologies', | ||
link: 'https://www.iqvia.com', | ||
imageSrc: '/img/sponsors/iqvia.png', | ||
altText: 'IQVIA Technologies', | ||
imageClass: 'inline-block px-4 sm:h-10', | ||
}, | ||
{ | ||
name: 'Postman', | ||
link: 'https://www.postman.com', | ||
imageSrc: '/img/sponsors/postman.png', | ||
altText: 'Postman', | ||
imageClass: 'inline-block px-2 sm:h-18 flex-shrink-0', | ||
}, | ||
{ | ||
name: 'Solace', | ||
link: 'https://www.solace.com', | ||
imageSrc: '/img/sponsors/solace.png', | ||
altText: 'Solace', | ||
imageClass: 'inline-block px-4 sm:h-10', | ||
}, | ||
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
import React from 'react'; | ||
import { mount } from 'cypress/react'; | ||
import Calendar from '../../components/Calendar'; | ||
import eventsData from '../../config/meetings.json'; | ||
|
||
describe('Calendar component', () => { | ||
beforeEach(() => { | ||
mount(<Calendar />); | ||
}); | ||
|
||
it('renders the upcoming events', () => { | ||
cy.get('[data-testid="Calendar-list-item"]').should('have.length', eventsData.length); | ||
}); | ||
|
||
it('renders the "View Calendar" button if events exist', () => { | ||
if (eventsData.length > 0) { | ||
cy.get('[data-testid="Calendar-button"]').should('be.visible'); | ||
} else { | ||
cy.get('[data-testid="Calendar-button"]').should('not.exist'); | ||
} | ||
}); | ||
|
||
it('renders the "No meetings scheduled" message if no events exist', () => { | ||
if (eventsData.length === 0) { | ||
cy.contains('There are no meetings scheduled for next few days.').should('be.visible'); | ||
} else { | ||
cy.contains('There are no meetings scheduled for next few days.').should('not.exist'); | ||
} | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
import React from 'react'; | ||
import { mount } from 'cypress/react'; | ||
import Caption from '../../components/Caption'; | ||
|
||
describe('Caption component', () => { | ||
beforeEach(() => { | ||
mount(<Caption>AsyncAPI</Caption>); | ||
}); | ||
|
||
it('renders the caption text correctly', () => { | ||
cy.contains('AsyncAPI').should('be.visible'); | ||
}); | ||
|
||
it('check correct CSS classes', () => { | ||
cy.get('[data-testid="Caption-paragraph"]').should('have.class', 'text-center').and('have.class', 'text-xs') | ||
.and('have.class', 'text-gray-500') | ||
.and('have.class', 'mt-2'); | ||
}); | ||
}); |
Oops, something went wrong.