cabbott / Tatami-dotnet

Tatami is a C# library for web application testing.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

#tatami Tatami.NET Tatami is a C# library for web application testing.

  • Manages test cases in CSV file like this.
    • HTTP request conditions to get test documents (Uri, Method, UseAgent, QueryString, PathInfos, Header, Cookie)
    • Test cases and Assert conditions
  • Verifies HTTP response information.
    • HTTP response header, cookies, status code, URL
    • Document structure (HTML, XML, JSON and Other text format)
  • Can be integrated in major C# test frameworks and CI.
    • NUnit, MS Test, Jenkins, TeamCity, etc.

Tatami enables you to reduce test codes and help review for test cases.

Contents

This library covers the following test types.

  • Integration Test
  • Acceptance Test
  • Smoke Test
  • (not for Unit Test)

Tatami provides the following test functions.

  • Manage HTTP request information, test cases and assert conditions in CSV.
  • Get expected and actual documents (such as HTML, XML, JSON and Other formats).
  • Test HTTP response information (Uri, Status Code, Header, Cookie, Format using XSD).
  • Test response documents using expected values, XPath and regular expression.
  • Provide failed information.

1. HTML page test (Wikipedia)

Test a HTML structure of "United States" page using static expected values.

  • This scenario covers to test between html values and static values in CSV.
  • See Wikipedia page test for details. sample1

2. HTML page test using Web API (Yahoo Weather)

Test a HTML structure of "New York" page using values from Web API (Yahoo Weather RSS).

  • Recent Web applications consume data created by Web API instead of database. This scenario will cover to test values between HTML and XML from Web API.
  • See Yahoo Weather page test for details. sample2

3. Web API test (XML/JSON)

  • Test Web API which returns XML/JSON using static values.
  • See Yahoo API test for details. sample3

See CSV implementation for details.

See BaseUriMapping.xml settings for details.

See UserAgentMapping.xml settings for details.

https://www.nuget.org/packages/Tatami.NET/

  1. Create a C# test project.
  2. Install Tatami library from nuget.org then sets this into the project.
  3. Create a BaseUriMapping.xml
  4. Create a UserAgentMapping.xml
  5. Create a CSV file including test cases.
  6. Create a test method.
  7. Run test.

Copyright (c) 2014 kenyamat. Licensed under MIT.

About

Tatami is a C# library for web application testing.