![]() |
VOOZH | about |
dotnet add package TestAny.Essentials.Api.Extensions --version 2.0.6
NuGet\Install-Package TestAny.Essentials.Api.Extensions -Version 2.0.6
<PackageReference Include="TestAny.Essentials.Api.Extensions" Version="2.0.6" />
<PackageVersion Include="TestAny.Essentials.Api.Extensions" Version="2.0.6" />Directory.Packages.props
<PackageReference Include="TestAny.Essentials.Api.Extensions" />Project file
paket add TestAny.Essentials.Api.Extensions --version 2.0.6
#r "nuget: TestAny.Essentials.Api.Extensions, 2.0.6"
#:package TestAny.Essentials.Api.Extensions@2.0.6
#addin nuget:?package=TestAny.Essentials.Api.Extensions&version=2.0.6Install as a Cake Addin
#tool nuget:?package=TestAny.Essentials.Api.Extensions&version=2.0.6Install as a Cake Tool
Build your Api test easily with few simple steps and this framework allows you to focus more on your Test. The wrapper allows to call the endpoints easily and provide different options on your request and response.
Overview
This framework is build as part of Selenium Essentials to provide a Api framework which allows to make calls to endpoint easily with enhanced data transformation capabilities.
- Api framework to write integration tests
-- Supports fluent way of endpoint definitions
-- Support most of the operations
-- Simple and easy to manage the tests
-- Excel data transformation and template processing
-- Data-driven testing with Excel integration
-- String template transformation with placeholders
Key Features:
- Excel Data Integration: Load and transform data from Excel files using attributes
- Template Processing: Transform string templates with {{placeholder}} syntax using Excel data
- Extension Methods: Convenient extension methods for string and data transformations
- Seamless Integration: Works with TestAny.Essentials.Api for enhanced testing capabilities
Excel Data Transformation:
- GetExcelDataSourceContent(): Retrieve Excel data from method attributes
- TransformWithExcelData(): Transform string templates using Excel data with {{key}} placeholders
- Support for column mapping and worksheet selection
- Automatic data type handling and conversion
Example,
return new TestApiHttp()
.SetEnvironment("http://api.openweathermap.org/")
.PrepareRequest("/data/2.5/forecase")
.Get()
.ResponseBody
.ContentJson;
// Excel data transformation example
var template = "Hello {{name}}, your age is {{age}}";
var transformedContent = template.TransformWithExcelData(excelData);
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net5.0 net5.0 was computed. net5.0-windows net5.0-windows was computed. net6.0 net6.0 was computed. net6.0-android net6.0-android was computed. net6.0-ios net6.0-ios was computed. net6.0-maccatalyst net6.0-maccatalyst was computed. net6.0-macos net6.0-macos was computed. net6.0-tvos net6.0-tvos was computed. net6.0-windows net6.0-windows was computed. net7.0 net7.0 was computed. net7.0-android net7.0-android was computed. net7.0-ios net7.0-ios was computed. net7.0-maccatalyst net7.0-maccatalyst was computed. net7.0-macos net7.0-macos was computed. net7.0-tvos net7.0-tvos was computed. net7.0-windows net7.0-windows was computed. net8.0 net8.0 was computed. net8.0-android net8.0-android was computed. net8.0-browser net8.0-browser was computed. net8.0-ios net8.0-ios was computed. net8.0-maccatalyst net8.0-maccatalyst was computed. net8.0-macos net8.0-macos was computed. net8.0-tvos net8.0-tvos was computed. net8.0-windows net8.0-windows was computed. net9.0 net9.0 was computed. net9.0-android net9.0-android was computed. net9.0-browser net9.0-browser was computed. net9.0-ios net9.0-ios was computed. net9.0-maccatalyst net9.0-maccatalyst was computed. net9.0-macos net9.0-macos was computed. net9.0-tvos net9.0-tvos was computed. net9.0-windows net9.0-windows was computed. net10.0 net10.0 was computed. net10.0-android net10.0-android was computed. net10.0-browser net10.0-browser was computed. net10.0-ios net10.0-ios was computed. net10.0-maccatalyst net10.0-maccatalyst was computed. net10.0-macos net10.0-macos was computed. net10.0-tvos net10.0-tvos was computed. net10.0-windows net10.0-windows was computed. |
| .NET Core | netcoreapp2.0 netcoreapp2.0 was computed. netcoreapp2.1 netcoreapp2.1 was computed. netcoreapp2.2 netcoreapp2.2 was computed. netcoreapp3.0 netcoreapp3.0 was computed. netcoreapp3.1 netcoreapp3.1 was computed. |
| .NET Standard | netstandard2.0 netstandard2.0 is compatible. netstandard2.1 netstandard2.1 was computed. |
| .NET Framework | net461 net461 was computed. net462 net462 was computed. net463 net463 was computed. net47 net47 was computed. net471 net471 was computed. net472 net472 was computed. net48 net48 was computed. net481 net481 was computed. |
| MonoAndroid | monoandroid monoandroid was computed. |
| MonoMac | monomac monomac was computed. |
| MonoTouch | monotouch monotouch was computed. |
| Tizen | tizen40 tizen40 was computed. tizen60 tizen60 was computed. |
| Xamarin.iOS | xamarinios xamarinios was computed. |
| Xamarin.Mac | xamarinmac xamarinmac was computed. |
| Xamarin.TVOS | xamarintvos xamarintvos was computed. |
| Xamarin.WatchOS | xamarinwatchos xamarinwatchos was computed. |
This package is not used by any NuGet packages.
This package is not used by any popular GitHub repositories.
Release 2.0.2
- Major refactoring: Excel data transformation features moved from TestAny.Essentials.Api to Extensions project
- Added ExcelDataTransformExtensions class with enhanced Excel data processing capabilities
- New GetExcelDataSourceContent() method for retrieving Excel data from method attributes
- New TransformWithExcelData() extension method for string template transformation using Excel data
- Improved separation of concerns: Excel-specific functionality now centralized in Extensions project
- Enhanced template processing with {{placeholder}} syntax support
- Better column mapping support with original and mapped column names
- Maintains backward compatibility while providing cleaner architecture
Release 1.0.5.9
- Retry on every action [Get, Post, Delete, Put] has now additional parameter to control the timeout error from server. retryOnRequestTimeout, can be set to true/false to fail when the request timeout or to retry
- AddingCookies is renamed to AddCookies under TestApiRequest
- Option to control
-- Set Timeout
-- Auto Redirection on the server for a request
-- Extract Domain cookies
-- No Cache
Release 1.0.5.4
- Api Request can now accept SetQueryParameter and SetJsonBody with any object passed
Release 1.0.5.2
- Api Retry option now has ability to control on which httpstatuscode the retry should occur
Release 1.0.5.2
- Introduce Api framework with PUT PATCH commands
-- WithRetry option with time on interval
-- Response contains cookies extracted from domains
-- Cookie extension to merge and contact cookies
-- Introducing Proxy for API request based on the user data
-- Introducing Certificates to be passed on the request
-- Response has more request details from headers to cookies
- Tests are now upgraded to .NET 6
Release 1.0.5.1
- Bug fix when loading ApiResponse as HtmlContent
Release 1.0.5
- Introduce TestAny.Essentials.Core
- Introduce TestAny.Essentials.Api. All Api related functionality are moved into this new package
- There are some breaking changes
-- SeAppConfig is renamed to TestAnyAppConfig
-- TestAnyAppConfig is now moved into TestAny.Essentials.Core
-- TestContextHelper is renamed to TestAnyTestContextHelper
-- TestAnyTestContextHelper is now moved into TestAny.Essentials.Core
-- Dtos models are now moved into the Core project
Release 1.0.4
- Introduction of Selenium.Essentials.Api for Api testing
- Usage of utilities from Pj.Library
- Remove Utility class from Selenium Essentials
- Move properties from Utility class to SeAppConfig class
- Move InitializeFramework(..) from Utility to SeAppConfig class