Create an integration tests project
Procedure
-
In your Sitefinity project, create a new class library project. The project build output path must lead to the
binfolder. -
Install
Progress.Sitefinity.TestIntegration.FrameworkNuGet package in your Sitefinity project. -
For the
IntegrationTestsSettings.jsonfile, set theCopy to Output Directorybuild property toCopy if newerorCopy always.NOTE: Your Sitefinity website must contain the configuration file
IntegrationTestsSettings.jsonin the Sitefinity projectbinfolder. -
Update the integration tests settings to match your project.
Note that the default Sitefinity authentication protocol OAuth 2.0 must be used. For more information, see Configure Oauth2. -
(Optional) You can customize when the
ClassCleanup()methods are executed by using the assembly attributeClassCleanupExecution:
Add[assembly: ClassCleanupExecution(ClassCleanupBehavior.EndOfClass)]By default, the
ClassCleanupExecutionis after all tests of the assembly are executed.
You can change this by using the assembly attributeClassCleanupExecution.ClassCleanupBehavior.EndOfAssembly: Called after all tests of the assembly are executedClassCleanupBehavior.EndOfClass: Called after all tests of the class are executed