Skip to content

Add jest setup for site #1187

Add jest setup for site

Add jest setup for site #1187

GitHub Actions / Tests succeeded Oct 25, 2024 in 0s

19 passed, 0 failed and 0 skipped

Tests passed successfully

Report Passed Failed Skipped Time
api/junit.xml 6✅ 6s
site/junit.xml 13✅ 2s

✅ api/junit.xml

6 tests were completed in 6s with 6 passed, 0 failed and 0 skipped.

Test suite Passed Failed Skipped Time
AccessControlService 6✅ 6s

✅ AccessControlService

AccessControlService getPermissionsForUser should return no permissions by default
  ✅ AccessControlService getPermissionsForUser should return no permissions by default
AccessControlService getPermissionsForUser should return all permissions for Vivid Planet employee
  ✅ AccessControlService getPermissionsForUser should return all permissions for Vivid Planet employee
AccessControlService getPermissionsForUser should return all permissions for Admin
  ✅ AccessControlService getPermissionsForUser should return all permissions for Admin
AccessControlService getContentScopesForUser should return no content scopes by default
  ✅ AccessControlService getContentScopesForUser should return no content scopes by default
AccessControlService getContentScopesForUser should return all content scopes for Vivid Planet employee
  ✅ AccessControlService getContentScopesForUser should return all content scopes for Vivid Planet employee
AccessControlService getContentScopesForUser should return all content scopes for Admin
  ✅ AccessControlService getContentScopesForUser should return all content scopes for Admin

✅ site/junit.xml

13 tests were completed in 2s with 13 passed, 0 failed and 0 skipped.

Test suite Passed Failed Skipped Time
HiddenIfInvalidLink 3✅ 860ms
isValidLink 10✅ 685ms

✅ HiddenIfInvalidLink

HiddenIfInvalidLink should render children if previewType is BlockPreview
  ✅ HiddenIfInvalidLink should render children if previewType is BlockPreview
HiddenIfInvalidLink should render children if link is valid
  ✅ HiddenIfInvalidLink should render children if link is valid
HiddenIfInvalidLink should not render children if link is invalid
  ✅ HiddenIfInvalidLink should not render children if link is invalid

✅ isValidLink

isValidLink should return true for valid internal link
  ✅ isValidLink should return true for valid internal link
isValidLink should return false for invalid internal link
  ✅ isValidLink should return false for invalid internal link
isValidLink should return true for valid external link
  ✅ isValidLink should return true for valid external link
isValidLink should return false for invalid external link
  ✅ isValidLink should return false for invalid external link
isValidLink should return true for valid damFileDownload link
  ✅ isValidLink should return true for valid damFileDownload link
isValidLink should return false for invalid damFileDownload link
  ✅ isValidLink should return false for invalid damFileDownload link
isValidLink should return true for valid email link
  ✅ isValidLink should return true for valid email link
isValidLink should return false for invalid email link
  ✅ isValidLink should return false for invalid email link
isValidLink should return true for valid phone link
  ✅ isValidLink should return true for valid phone link
isValidLink should return false for invalid phone link
  ✅ isValidLink should return false for invalid phone link