Sitecore

How to Mock Rendering Parameters in Unit Test – Sitecore

Now that we created a cool components with rendering parameters (see Using Rendering Parameters to Inject Data into Hidden Input), we can write a unit test. Sitecore’s Rendering class has a publicly accessible string field called Parameters. This is the rendering parameter string get populated on page rendering. Mocking is …

Sitecore

Using Rendering Parameters to Inject Data into Hidden Input – Sitecore

What are rendering parameters? They are the additional key-value pair data you can feed to the Sitecore component in addition to data source. The textbook example would be adding an additional CSS class to the component. Content authors can customise the style of the component, like background colour or button …