Support items to show auto #185
GitHub Actions / Tests results
succeeded
Jan 6, 2025 in 1s
76 passed, 0 failed and 0 skipped
✅ junit-report.xml
76 tests were completed in 6s with 76 passed, 0 failed and 0 skipped.
Test suite | Passed | Failed | Skipped | Time |
---|---|---|---|---|
src/components/Carousel/Carousel.spec.ts | 1✅ | 29ms | ||
src/components/Icon/Icon.spec.ts | 3✅ | 71ms | ||
src/utils/calculateAverage.spec.ts | 5✅ | 5ms | ||
src/utils/camelCaseToKebabCase.spec.ts | 6✅ | 5ms | ||
src/utils/except.spec.ts | 1✅ | 7ms | ||
src/utils/getDraggedSlidesCount.spec.ts | 5✅ | 5ms | ||
src/utils/getNumberInRange.spec.ts | 5✅ | 4ms | ||
src/utils/getScaleMultiplier.spec.ts | 1✅ | 6ms | ||
src/utils/getSnapAlignOffset.spec.ts | 11✅ | 8ms | ||
src/utils/mapNumberToRange.spec.ts | 6✅ | 6ms | ||
src/utils/toCssValue.spec.ts | 4✅ | 3ms | ||
tests/integration/aria.spec.ts | 2✅ | 39ms | ||
tests/integration/carousel.spec.ts | 20✅ | 506ms | ||
tests/integration/navigation.spec.ts | 4✅ | 86ms | ||
tests/integration/pagination.spec.ts | 2✅ | 70ms |
✅ src/components/Carousel/Carousel.spec.ts
src/components/Carousel/Carousel.spec.ts
✅ Carousel.ts > It renders correctly
✅ src/components/Icon/Icon.spec.ts
src/components/Icon/Icon.spec.ts
✅ Icon.ts > It should error if no iconName
✅ Icon.ts > It should error if iconName is invalid
✅ Icon.ts > It should render standalone
✅ src/utils/calculateAverage.spec.ts
src/utils/calculateAverage.spec.ts
✅ calculateAverage > returns 0 for empty array
✅ calculateAverage > calculates average for single value
✅ calculateAverage > calculates average for multiple values
✅ calculateAverage > handles decimal numbers
✅ calculateAverage > handles negative numbers
✅ src/utils/camelCaseToKebabCase.spec.ts
src/utils/camelCaseToKebabCase.spec.ts
✅ camelCaseToKebabCase > converts single camelCase word to kebab-case
✅ camelCaseToKebabCase > converts multiple camelCase words to kebab-case
✅ camelCaseToKebabCase > handles strings with no uppercase letters
✅ camelCaseToKebabCase > handles empty strings
✅ camelCaseToKebabCase > handles strings with numbers
✅ camelCaseToKebabCase > handles strings with special characters
✅ src/utils/except.spec.ts
src/utils/except.spec.ts
✅ except > should return an object without keys
✅ src/utils/getDraggedSlidesCount.spec.ts
src/utils/getDraggedSlidesCount.spec.ts
✅ getDraggedSlidesCount > should calculate the correct number of slides for horizontal drag
✅ getDraggedSlidesCount > should calculate the correct number of slides for vertical drag
✅ getDraggedSlidesCount > should calculate the correct number of slides for reversed horizontal drag
✅ getDraggedSlidesCount > should calculate the correct number of slides for reversed vertical drag
✅ getDraggedSlidesCount > should handle zero drag
✅ src/utils/getNumberInRange.spec.ts
src/utils/getNumberInRange.spec.ts
✅ getCurrentSlideIndex > When the number inside the range should return the same value
✅ getCurrentSlideIndex > When the number is larger than the range should return the max value
✅ getCurrentSlideIndex > When the number is smaller than the range should return the min value
✅ getCurrentSlideIndex > When the min is larger than max should return val
✅ getCurrentSlideIndex > doesn`t bound a NaN min or max
✅ src/utils/getScaleMultiplier.spec.ts
src/utils/getScaleMultiplier.spec.ts
✅ getWidthMultiplier.ts > gets the transform matrix of an element
✅ src/utils/getSnapAlignOffset.spec.ts
src/utils/getSnapAlignOffset.spec.ts
✅ getSnapAlignOffset > with itemsToShow parameter > should return correct offset for start alignment
✅ getSnapAlignOffset > with itemsToShow parameter > should return correct offset for center/center-odd alignment
✅ getSnapAlignOffset > with itemsToShow parameter > should return correct offset for center-even alignment
✅ getSnapAlignOffset > with itemsToShow parameter > should return correct offset for end alignment
✅ getSnapAlignOffset > with slideSize and viewportSize parameters > should return correct offset for start alignment
✅ getSnapAlignOffset > with slideSize and viewportSize parameters > should return correct offset for center/center-odd alignment
✅ getSnapAlignOffset > with slideSize and viewportSize parameters > should return correct offset for center-even alignment
✅ getSnapAlignOffset > with slideSize and viewportSize parameters > should return correct offset for end alignment
✅ getSnapAlignOffset > edge cases > should return 0 when no parameters provided
✅ getSnapAlignOffset > edge cases > should return 0 for invalid alignment
✅ getSnapAlignOffset > edge cases > should handle equal viewport and slide sizes
✅ src/utils/mapNumberToRange.spec.ts
src/utils/mapNumberToRange.spec.ts
✅ getCurrentSlideIndex > When the number inside the range should return the same value
✅ getCurrentSlideIndex > When the number is larger than the range should return correctly mapped value
✅ getCurrentSlideIndex > When the number is smaller than the range should return correctly mapped value
✅ getCurrentSlideIndex > When min is non zero should return correctly mapped value
✅ getCurrentSlideIndex > Keeps float values less than 1 over max
✅ getCurrentSlideIndex > Wraps float values more than 1 over max
✅ src/utils/toCssValue.spec.ts
src/utils/toCssValue.spec.ts
✅ toCssValue > should convert number to px string
✅ toCssValue > should return string as is
✅ toCssValue > should handle zero correctly
✅ toCssValue > should handle empty string correctly
✅ tests/integration/aria.spec.ts
tests/integration/aria.spec.ts
✅ Aria.ts > renders properly with a carousel
✅ Aria.ts > doesn't render without a carousel
✅ tests/integration/carousel.spec.ts
tests/integration/carousel.spec.ts
✅ Carousel.ts > It renders *five* slides correctly
✅ Carousel.ts > Should display *one* visible item
✅ Carousel.ts > Should display *one* next item
✅ Carousel.ts > Should navigate to the focused slide
✅ Carousel.ts > Should navigate the carousel with arrow keys
✅ Carousel.ts > Should default itemsToShow to 1 if less than 1
✅ Carousel.ts > Should default itemsToShow to slidesCount if greater than slidesCount
✅ Slotted Carousel.ts > It renders *three* slides correctly
✅ Slotted Carousel.ts > Should display *one* visible item
✅ Slotted Carousel.ts > Should display *one* next item
✅ Wrap around Carousel.ts > renders wrapAround correctly
✅ SSR Carousel > renders server side properly
✅ SSR Carousel > renders slotted server side properly
✅ SSR Carousel > doesn't get hydration mismatch with breakpoints
✅ Carousel Clone Count Logic > should not clone slides when wrapAround is disabled
✅ Carousel Clone Count Logic > should calculate correct clone counts at start position
✅ Carousel Clone Count Logic > should adjust clone counts when scrolling to middle
✅ Carousel Clone Count Logic > should handle edge case at last slide
✅ Carousel Clone Count Logic > should handle decimal itemsToShow with itemsToScroll
✅ Carousel Clone Count Logic > should handle minimal setup with a single item
✅ tests/integration/navigation.spec.ts
tests/integration/navigation.spec.ts
✅ Navigation.ts > renders properly with a carousel
✅ Navigation.ts > doesn't render without a carousel
✅ Navigation.ts > inherits attrs on buttons
✅ Navigation.ts > renders custom icons
✅ tests/integration/pagination.spec.ts
tests/integration/pagination.spec.ts
✅ Navigation.ts > renders properly with a carousel
✅ Navigation.ts > doesn't render without a carousel
Loading