Skip to content

fix: resolve css subentry path in extract-style #6708

fix: resolve css subentry path in extract-style

fix: resolve css subentry path in extract-style #6708

GitHub Actions / UT Tests report-ubuntu-latest succeeded Feb 6, 2024 in 0s

119 passed, 0 failed and 0 skipped

Tests passed successfully

Report Passed Failed Skipped Time
apps/showcase/dist-test/ut-report.xml 25✅ 46s
packages/@o3r/design/dist-test/ut-report.xml 39✅ 24s
packages/@o3r/storybook/dist-test/ut-report.xml 23✅ 15s
packages/@o3r/styling/dist-test/ut-report.xml 32✅ 35s

✅ apps/showcase/dist-test/ut-report.xml

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

Test suite Passed Failed Skipped Time
AppComponent 1✅ 2s
BasicPresComponent 1✅ 995ms
ComponentReplacementComponent 1✅ 1s
ComponentReplacementPresComponent 1✅ 1s
ConfigurationComponent 1✅ 8s
ConfigurationPresComponent 1✅ 1s
CopyTextPresComponent 1✅ 437ms
DatePickerHebrewInputPresComponent 1✅ 963ms
DatePickerInputPresComponent 1✅ 934ms
DesignTokenComponent 1✅ 2s
DesignTokenPresComponent 1✅ 868ms
DynamicContentComponent 1✅ 2s
DynamicContentPresComponent 1✅ 984ms
HomeComponent 1✅ 1s
InPageNavPresComponent 1✅ 792ms
LocalizationComponent 1✅ 4s
LocalizationPresComponent 1✅ 21s
OtterPickerPresComponent 1✅ 826ms
RulesEngineComponent 1✅ 30s
RulesEnginePresComponent 1✅ 25s
RunAppLocallyComponent 1✅ 2s
ScrollBackTopPresComponent 1✅ 507ms
SdkComponent 1✅ 2s
SdkPresComponent 1✅ 1s
SidenavPresComponent 1✅ 1s

✅ AppComponent

AppComponent should create the app
  ✅ AppComponent should create the app

✅ BasicPresComponent

BasicPresComponent should create
  ✅ BasicPresComponent should create

✅ ComponentReplacementComponent

ComponentReplacementComponent should create
  ✅ ComponentReplacementComponent should create

✅ ComponentReplacementPresComponent

ComponentReplacementPresComponent should create
  ✅ ComponentReplacementPresComponent should create

✅ ConfigurationComponent

ConfigurationComponent should create
  ✅ ConfigurationComponent should create

✅ ConfigurationPresComponent

ConfigurationPresComponent should create
  ✅ ConfigurationPresComponent should create

✅ CopyTextPresComponent

CopyTextPresComponent should create
  ✅ CopyTextPresComponent should create

✅ DatePickerHebrewInputPresComponent

DatePickerHebrewInputPresComponent should create
  ✅ DatePickerHebrewInputPresComponent should create

✅ DatePickerInputPresComponent

DatePickerInputPresComponent should create
  ✅ DatePickerInputPresComponent should create

✅ DesignTokenComponent

DesignTokenComponent should create
  ✅ DesignTokenComponent should create

✅ DesignTokenPresComponent

DesignTokenPresComponent should create
  ✅ DesignTokenPresComponent should create

✅ DynamicContentComponent

DynamicContentComponent should create
  ✅ DynamicContentComponent should create

✅ DynamicContentPresComponent

DynamicContentPresComponent should create
  ✅ DynamicContentPresComponent should create

✅ HomeComponent

HomeComponent should create
  ✅ HomeComponent should create

✅ InPageNavPresComponent

InPageNavPresComponent should create
  ✅ InPageNavPresComponent should create

✅ LocalizationComponent

LocalizationComponent should create
  ✅ LocalizationComponent should create

✅ LocalizationPresComponent

LocalizationPresComponent should create
  ✅ LocalizationPresComponent should create

✅ OtterPickerPresComponent

OtterPickerPresComponent should create
  ✅ OtterPickerPresComponent should create

✅ RulesEngineComponent

RulesEngineComponent should create
  ✅ RulesEngineComponent should create

✅ RulesEnginePresComponent

RulesEnginePresComponent should create
  ✅ RulesEnginePresComponent should create

✅ RunAppLocallyComponent

RunAppLocallyComponent should create
  ✅ RunAppLocallyComponent should create

✅ ScrollBackTopPresComponent

ScrollBackTopPresComponent should create
  ✅ ScrollBackTopPresComponent should create

✅ SdkComponent

SdkComponent should create
  ✅ SdkComponent should create

✅ SdkPresComponent

SdkPresComponent should create
  ✅ SdkPresComponent should create

✅ SidenavPresComponent

SidenavPresComponent should create
  ✅ SidenavPresComponent should create

✅ packages/@o3r/design/dist-test/ut-report.xml

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

Test suite Passed Failed Skipped Time
Add Design Token to component 3✅ 22s
Design Token generator 6✅ 11s
Design Token Parser 5✅ 1s
Design Token Renderer 4✅ 891ms
Extract Token schematic 2✅ 21s
getCssStyleContentUpdater 3✅ 472ms
getCssTokenValueRenderer 4✅ 1s
getMetadataStyleContentUpdater 1✅ 702ms
getMetadataTokenDefinitionRenderer 2✅ 614ms
getMetadataTokenDefinitionRenderer 2✅ 842ms
getMetadataTokenValueRenderer 2✅ 855ms
getSassTokenDefinitionRenderer 2✅ 848ms
isO3rPrivateVariable 3✅ 554ms

✅ Add Design Token to component

Add Design Token to component should create the design token file
  ✅ Add Design Token to component should create the design token file
Add Design Token to component should create the design token file and target styling file
  ✅ Add Design Token to component should create the design token file and target styling file
Add Design Token to component should create the design token file with correct name
  ✅ Add Design Token to component should create the design token file with correct name

✅ Design Token generator

Design Token generator CSS renderer should render variable in CSS
  ✅ Design Token generator CSS renderer should render variable in CSS
Design Token generator CSS renderer should render variable with important flag
  ✅ Design Token generator CSS renderer should render variable with important flag
Design Token generator CSS renderer should render variable with prefix
  ✅ Design Token generator CSS renderer should render variable with prefix
Design Token generator CSS renderer should render variable in existing CSS
  ✅ Design Token generator CSS renderer should render variable in existing CSS
Design Token generator CSS renderer should render private variable to sass if requested
  ✅ Design Token generator CSS renderer should render private variable to sass if requested
Design Token generator Metadata Renderer should render valid metadata
  ✅ Design Token generator Metadata Renderer should render valid metadata

✅ Design Token Parser

Design Token Parser parseDesignToken generate a simple type variable
  ✅ Design Token Parser parseDesignToken generate a simple type variable
Design Token Parser parseDesignToken generate an alias variable
  ✅ Design Token Parser parseDesignToken generate an alias variable
Design Token Parser parseDesignToken generate a complex variable
  ✅ Design Token Parser parseDesignToken generate a complex variable
Design Token Parser parseDesignTokenFile should read the file according to the reader
  ✅ Design Token Parser parseDesignTokenFile should read the file according to the reader
Design Token Parser parseDesignTokenFile should throw if invalid JSON Token
  ✅ Design Token Parser parseDesignTokenFile should throw if invalid JSON Token

✅ Design Token Renderer

Design Token Renderer computeFileToUpdatePath should return default file if not specified
  ✅ Design Token Renderer computeFileToUpdatePath should return default file if not specified
Design Token Renderer computeFileToUpdatePath should return file specified by the token
  ✅ Design Token Renderer computeFileToUpdatePath should return file specified by the token
Design Token Renderer renderDesignTokens should call the process for all variables
  ✅ Design Token Renderer renderDesignTokens should call the process for all variables
Design Token Renderer renderDesignTokens should update all the files
  ✅ Design Token Renderer renderDesignTokens should update all the files

✅ Extract Token schematic

Extract Token schematic should correctly extract the Design Token
  ✅ Extract Token schematic should correctly extract the Design Token
Extract Token schematic should Update the original file
  ✅ Extract Token schematic should Update the original file

✅ getCssStyleContentUpdater

getCssStyleContentUpdater should render CSS Values
  ✅ getCssStyleContentUpdater should render CSS Values
getCssStyleContentUpdater should add tags to new file
  ✅ getCssStyleContentUpdater should add tags to new file
getCssStyleContentUpdater should only update within tag part
  ✅ getCssStyleContentUpdater should only update within tag part

✅ getCssTokenValueRenderer

getCssTokenValueRenderer should render valid CSS value
  ✅ getCssTokenValueRenderer should render valid CSS value
getCssTokenValueRenderer should render valid CSS var
  ✅ getCssTokenValueRenderer should render valid CSS var
getCssTokenValueRenderer should render valid CSS var of not print value
  ✅ getCssTokenValueRenderer should render valid CSS var of not print value
getCssTokenValueRenderer should render invalid reference and raise warning
  ✅ getCssTokenValueRenderer should render invalid reference and raise warning

✅ getMetadataStyleContentUpdater

getMetadataStyleContentUpdater should render valid JSON object
  ✅ getMetadataStyleContentUpdater should render valid JSON object

✅ getMetadataTokenDefinitionRenderer

getMetadataTokenDefinitionRenderer should rely on given tokenValueRenderer
  ✅ getMetadataTokenDefinitionRenderer should rely on given tokenValueRenderer
getMetadataTokenDefinitionRenderer should use private renderer for private variable
  ✅ getMetadataTokenDefinitionRenderer should use private renderer for private variable

✅ getMetadataTokenDefinitionRenderer

getMetadataTokenDefinitionRenderer should rely on given tokenValueRenderer
  ✅ getMetadataTokenDefinitionRenderer should rely on given tokenValueRenderer
getMetadataTokenDefinitionRenderer should render valid JSON object
  ✅ getMetadataTokenDefinitionRenderer should render valid JSON object

✅ getMetadataTokenValueRenderer

getMetadataTokenValueRenderer should rely on given cssValueRenderer
  ✅ getMetadataTokenValueRenderer should rely on given cssValueRenderer
getMetadataTokenValueRenderer should render valid JSON object
  ✅ getMetadataTokenValueRenderer should render valid JSON object

✅ getSassTokenDefinitionRenderer

getSassTokenDefinitionRenderer should rely on given tokenValueRenderer
  ✅ getSassTokenDefinitionRenderer should rely on given tokenValueRenderer
getSassTokenDefinitionRenderer should prefix private variable
  ✅ getSassTokenDefinitionRenderer should prefix private variable

✅ isO3rPrivateVariable

isO3rPrivateVariable should determine the variable as ignored
  ✅ isO3rPrivateVariable should determine the variable as ignored
isO3rPrivateVariable should determine the variable as not ignored
  ✅ isO3rPrivateVariable should determine the variable as not ignored
isO3rPrivateVariable should determine the alias variable as not ignored
  ✅ isO3rPrivateVariable should determine the alias variable as not ignored

✅ packages/@o3r/storybook/dist-test/ut-report.xml

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

Test suite Passed Failed Skipped Time
Configuration Metadata setup 5✅ 12s
generateThemeCss 2✅ 871ms
generateThemeCss 2✅ 2s
Localization Metadata setup 4✅ 12s
Styling Metadata setup 10✅ 12s

✅ Configuration Metadata setup

Configuration Metadata setup should register the metadata
  ✅ Configuration Metadata setup should register the metadata
Configuration Metadata setup should retrieve the metadata
  ✅ Configuration Metadata setup should retrieve the metadata
Configuration helper extractConfiguration should extract description from metadata
  ✅ Configuration helper extractConfiguration should extract description from metadata
Configuration helper retrieveConfigFromProps should extract only config properties
  ✅ Configuration helper retrieveConfigFromProps should extract only config properties
Configuration helper retrieveConfigFromProps should return empty object if no config property found
  ✅ Configuration helper retrieveConfigFromProps should return empty object if no config property found

✅ generateThemeCss

generateThemeCss should generate a css file
  ✅ generateThemeCss should generate a css file
generateThemeCss should generate a css file from diff
  ✅ generateThemeCss should generate a css file from diff

✅ generateThemeCss

generateThemeCss should generate a css file
  ✅ generateThemeCss should generate a css file
generateThemeCss should generate a css file from diff
  ✅ generateThemeCss should generate a css file from diff

✅ Localization Metadata setup

Localization Metadata setup should register the metadata
  ✅ Localization Metadata setup should register the metadata
Localization Metadata setup should retrieve the metadata
  ✅ Localization Metadata setup should retrieve the metadata
Localization helper extractLocalization should extract description from metadata
  ✅ Localization helper extractLocalization should extract description from metadata
Localization helper getLocalizations should extract key/value from metadata
  ✅ Localization helper getLocalizations should extract key/value from metadata

✅ Styling Metadata setup

Styling Metadata setup should register the metadata
  ✅ Styling Metadata setup should register the metadata
Styling Metadata setup should retrieve the metadata
  ✅ Styling Metadata setup should retrieve the metadata
Styling Helpers setCssVariable should create a new style element
  ✅ Styling Helpers setCssVariable should create a new style element
Styling Helpers setCssVariable should edit an existing variable
  ✅ Styling Helpers setCssVariable should edit an existing variable
Styling Helpers getTypeAndValue should return a color editor for color
  ✅ Styling Helpers getTypeAndValue should return a color editor for color
Styling Helpers getTypeAndValue should return a text editor for color
  ✅ Styling Helpers getTypeAndValue should return a text editor for color
Styling Helpers extractStyling should extract component variable
  ✅ Styling Helpers extractStyling should extract component variable
Styling Helpers extractStyling should not extract incorrect variable
  ✅ Styling Helpers extractStyling should not extract incorrect variable
Styling Helpers extractStyling should return the final value of the referenced variable
  ✅ Styling Helpers extractStyling should return the final value of the referenced variable
Styling Helpers getThemeVariables should extract theme variable only
  ✅ Styling Helpers getThemeVariables should extract theme variable only

✅ packages/@o3r/styling/dist-test/ut-report.xml

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

Test suite Passed Failed Skipped Time
Add Theming 2✅ 6s
CSS Variable extractor 2✅ 15s
Styling Extractor Builder 1✅ 18s
Theming functions 2✅ 10s
Theming functions 2✅ 426ms
Theming mixins 3✅ 10s
Theming mixins 3✅ 756ms
undefined 1✅ 109ms
Update Styling imports 1✅ 2s
Update v10 7✅ 14s
Utils function 4✅ 9s
Utils function 4✅ 729ms

✅ Add Theming

Add Theming should create the theming file and update the style file
  ✅ Add Theming should create the theming file and update the style file
Add Theming should throw if we add theming to a component that already has it
  ✅ Add Theming should throw if we add theming to a component that already has it

✅ CSS Variable extractor

CSS Variable extractor Sass file content parsing should correctly extract variable details
  ✅ CSS Variable extractor Sass file content parsing should correctly extract variable details
CSS Variable extractor Sass file content parsing should override variable details
  ✅ CSS Variable extractor Sass file content parsing should override variable details

✅ Styling Extractor Builder

Styling Extractor Builder should extract css variables
  ✅ Styling Extractor Builder should extract css variables

✅ Theming functions

Theming functions var should define new variable
  ✅ Theming functions var should define new variable
Theming functions var should define new complex variable
  ✅ Theming functions var should define new complex variable

✅ Theming functions

Theming functions var should define new variable
  ✅ Theming functions var should define new variable
Theming functions var should define new complex variable
  ✅ Theming functions var should define new complex variable

✅ Theming mixins

Theming mixins var should define new variable
  ✅ Theming mixins var should define new variable
Theming mixins var should override previous metadata
  ✅ Theming mixins var should override previous metadata
Theming mixins var should not generate null variable
  ✅ Theming mixins var should not generate null variable

✅ Theming mixins

Theming mixins var should define new variable
  ✅ Theming mixins var should define new variable
Theming mixins var should override previous metadata
  ✅ Theming mixins var should override previous metadata
Theming mixins var should not generate null variable
  ✅ Theming mixins var should not generate null variable

✅ undefined

 should be removed as soon as we have one test in this package
  ✅ should be removed as soon as we have one test in this package

✅ Update Styling imports

Update Styling imports should update otter imports and scoped functions/variables in scss files
  ✅ Update Styling imports should update otter imports and scoped functions/variables in scss files

✅ Update v10

Update v10 Update SCSS Import should not update a TS file
  ✅ Update v10 Update SCSS Import should not update a TS file
Update v10 Update SCSS Import should not update a file without Otter dependency
  ✅ Update v10 Update SCSS Import should not update a file without Otter dependency
Update v10 Update SCSS Import should not update a file with Otter import with theme function only
  ✅ Update v10 Update SCSS Import should not update a file with Otter import with theme function only
Update v10 Update SCSS Import should update a file with Otter theme usage
  ✅ Update v10 Update SCSS Import should update a file with Otter theme usage
Update v10 Update SCSS Import should update a file with Otter theme usage with non-standard alias
  ✅ Update v10 Update SCSS Import should update a file with Otter theme usage with non-standard alias
Update v10 Update SCSS Import should update a file with Otter theme usage and clean previous dep
  ✅ Update v10 Update SCSS Import should update a file with Otter theme usage and clean previous dep
Update v10 Update SCSS Import should update a file with Otter theme usage without removing the import to the previous dep
  ✅ Update v10 Update SCSS Import should update a file with Otter theme usage without removing the import to the previous dep

✅ Utils function

Utils function multi-map-merge should merge the list of map into one map
  ✅ Utils function multi-map-merge should merge the list of map into one map
Utils function multi-map-merge should return empty if called without arguments
  ✅ Utils function multi-map-merge should return empty if called without arguments
Utils function get-mandatory should return the requested key value
  ✅ Utils function get-mandatory should return the requested key value
Utils function get-mandatory should fail if the key is no included in the map
  ✅ Utils function get-mandatory should fail if the key is no included in the map

✅ Utils function

Utils function multi-map-merge should merge the list of map into one map
  ✅ Utils function multi-map-merge should merge the list of map into one map
Utils function multi-map-merge should return empty if called without arguments
  ✅ Utils function multi-map-merge should return empty if called without arguments
Utils function get-mandatory should return the requested key value
  ✅ Utils function get-mandatory should return the requested key value
Utils function get-mandatory should fail if the key is no included in the map
  ✅ Utils function get-mandatory should fail if the key is no included in the map