Atata Framework 3 is released with a set of improvements and removal of deprecated functionality.
Migrating to Atata 3
There was a lot of breaking changes made in Atata 3. Please check out information on all breaking changes and migration process in the Upgrade to Atata 3 guide, which was created specifically to help with upgrade.
New AtataContext.GlobalProperties
Some of the AtataContext properties and AtataContextBuilder methods were moved to the new AtataContext.GlobalProperties static property.
Global properties can be set once before any AtataContext creation (in global setup method),
and those properties spread all over the AtataContexts.
Members of AtataContextGlobalProperties
public AtataContextModeOfCurrent ModeOfCurrent { get; set; }
public DateTime BuildStartUtc { get; }
public DateTime BuildStart { get; }
public TimeZoneInfo TimeZone { get; set; }
public string ArtifactsRootPathTemplate { get; set; }
public DirectorySubject ArtifactsRoot { get; }
public string ArtifactsRootPath { get; }
public AtataContextGlobalProperties UseDefaultArtifactsRootPathTemplateIncludingBuildStart(bool include);
public AtataContextGlobalProperties UseArtifactsRootPathTemplate(string directoryPathTemplate);
public AtataContextGlobalProperties UseUtcTimeZone();
public AtataContextGlobalProperties UseTimeZone(string timeZoneId);
public AtataContextGlobalProperties UseTimeZone(TimeZoneInfo timeZone);
public AtataContextGlobalProperties UseModeOfCurrent(AtataContextModeOfCurrent mode);
ArtifactsRoot extracted from Artifacts
Before the v3, Artifacts path was an absolute path to AtataContext artifacts.
Now Artifacts path is split into 2 parts, basically it becomes a path relative to Artifacts Root.
Default ArtifactsRoot path is "{basedir}/artifacts/{build-start:yyyyMMddTHHmmss}".
Default Artifacts path is "{test-suite-name-sanitized:/*}{test-name-sanitized:/*}".
ArtifactsRoot properties and methods are located in AtataContext.GlobalProperties.
Logging changes
Changed default log date/time format by cutting ten thousandths of a second
Updated date/time format in TextOutputLogConsumer, NLogFileConsumer and LoggingBrowserLogHandler.
2024-02-07 14:03:46.1234
->
2024-02-07 14:03:46.123
Removed navigation trace log entries
The navigation trace logs, basically, duplicated the wrapping informational logs.
2024-02-17 20:50:46.792 INFO > Go to "Test" page by URL http://localhost:50549
2024-02-17 20:50:46.793 TRACE - > Navigate to URL http://localhost:50549/
2024-02-17 20:50:46.954 TRACE - < Navigate to URL http://localhost:50549/ (0.160s)
2024-02-17 20:50:46.961 INFO < Go to "Test" page by URL http://localhost:50549 (0.169s)
->
2024-02-17 20:50:46.792 INFO > Go to "Test" page by URL http://localhost:50549
2024-02-17 20:50:46.961 INFO < Go to "Test" page by URL http://localhost:50549 (0.169s)
Changed log level of “Starting” and “Finished” test log messages from Info to Debug
2024-04-15 21:01:07.321 INFO Starting test: AtataSampleApp.UITests.SignInTests.SignIn
2024-04-15 21:01:07.466 TRACE > Initialize AtataContext
...
2024-04-15 21:01:09.368 INFO Finished test
Total time: 2.109s
...
->
2024-04-15 21:01:07.321 DEBUG Starting test: AtataSampleApp.UITests.SignInTests.SignIn
2024-04-15 21:01:07.466 TRACE > Initialize AtataContext
...
2024-04-15 21:01:09.368 DEBUG Finished test
Total time: 2.109s
...
Atata 3 changelog
Breaking changes
- minor
#808 Remove obsolete types and members related to
UIComponent - minor #809 Remove obsolete logging/reporting members
- minor #810 Remove obsolete event handler types
- minor
#811 Remove obsolete
AtataContextBuildermethods - minor
#812 Remove obsolete
AtataContextmembers - minor #813 Remove obsolete attributes
- minor #814 Remove obsolete event types
- minor #815 Remove other obsolete type members
- major #817 Remove screenshot consumers functionality
- major #822 Extract Artifacts Root path out of Artifacts path
- major
#823 Move
TimeZoneinstance property ofAtataContexttoAtataContext.GlobalProperties - minor
#824 Move
BuildStartandBuildStartUtcstatic properties ofAtataContexttoAtataContext.GlobalProperties - minor
#825 Move
ModeOfCurrentstatic property ofAtataContexttoAtataContext.GlobalProperties - minor
#827 Replace file path configuration of
NLogFileConsumerwith singleWithFileNameTemplatemethod - minor
#828 Update sanitization approach of
TestInfopropertiesNameSanitizedandSuiteNameSanitized - minor
#829 Apply
[FindByAlt]attribute toImage<TOwner>control - minor #833 Use Atata.WebDriverExtras package v3.0.0
New features
- minor
#826 Add
ArtifactsPathproperty toAtataContext - minor
#830
TableHeaderList<TItem, TOwner>with string indexer
Changes and enhancements
- minor
#816 Change
additionalVariablesparameter type inAtataContext.Fill*TemplateStringmethods - minor #818 Update default page snapshot file name template
- minor
#819 Change
TakePageSnapshotLogSectionlog level fromInfotoTrace - minor
#820 Change log level of “Starting” and “Finished” test log messages from
InfotoDebug - minor #821 Change default log date/time format by cutting ten thousandths of a second
- minor #831 Remove navigation trace log entries
- minor #832 Use Selenium.WebDriver package v4.19.0
Atata.Configuration.Json 3 changelog
Breaking changes
- major #111 Use Atata package v3.0.0
- major #112 Remove screenshot consumers configuration
- major
#113 Replace
"artifactsPath"configuration property with"artifactsPathTemplate" - major
#114 Remove
"timeZone"configuration property - major
#115 Replace file path configuration of
"nlog-file"log consumer with single"fileNameTemplate"configuration property - minor
#116 Remove obsolete configuration properties:
"logNUnitError","takeScreenshotOnNUnitError","takePageSnapshotOnNUnitError","onCleanUpAddArtifactsToNUnitTestContext","onCleanUpAddDirectoryFilesToNUnitTestContext" - minor
#117 Remove obsolete configuration properties:
"retryTimeout"and"retryInterval" - minor
#118 Remove obsolete log consumer configuration property
"sectionFinish"