Git Product home page Git Product logo

testrailintegrations's Introduction

TestRail integrations


A Java client library codepine.

Maven Central

Quick Start


Maven Dependency

<dependency>
  <groupId>com.github.ivanovvlad9626</groupId>
  <artifactId>TestRail</artifactId>
  <version>LATEST</version>
</dependency>

Gradle Dependency

compile 'com.github.ivanovvlad9626:TestRail:+'

Example Usage

  • Create file testRail.properties in src/main/resources/
WARNING!
  • Please don't use sections and projects!
  • Please don't use section and sections! Use one.
  • Please don't use project and projects! Use one.

delete or comment not used property.

nameProject = Name project. This text add descriptions in testRung
hostTR = http://past-you-url
testRailIntegrations = true //Flag on/off integrations.
loginTR = Login in TestRail.
passTR = Password in TestRail.
newMilestone = Name Milestone "Test integrations".
openMilestone = If you have Milestone. Paste this name milestone.
testRun = If you have TestRun. Paste this name TestRun.
regress = true //If you need not close Milestone, if all test passed. false close Milestone if all test passed.
section = Name Section in TestRail contains test cases.
sections = TestClass:NameSection, TestClass1:NameSections1
project = Name Project in TestRail.
projects = TestClass:NameProject, TestClass1:NameProject1
  • Add listener in TestNG open Run/Debug Configuration, Templates -> TestNG -> Listeners -> press plus btn -> paste name class TestRailListener or use gradle
ru.integrations.testRail.listeners.TestRailListener

Example gradle

test {
    useTestNG() {
        listeners << 'ru.integrations.testRail.listeners.TestRailListener'

    }
    testLogging {
        showStandardStreams = true
        events "PASSED", "FAILED", "SKIPPED"
        exceptionFormat = "full"
    }

    test.outputs.upToDateWhen { false }
}
  • If you use Rest-Assured, then you can use the ListenerRestAssured listener. He will add to the request and response, in the result of the cases that did not pass.

Add this code with method initialization RestAssured data.

 public static RequestSpecification base() {
        RequestSpecification builder = RestAssured.given();
        builder.baseUri("test.test.com");
        builder.basePath("/api");
        builder.port(5010);
        builder.filter(new ListenerRestAssured());
        return builder;
    }
    
    public void getProfile(){
        RestAssured
                .given()
                .spec(base())
                .get("/profile")
                .then()
                .statusCode(200);
    }
  • Field annotation in test method.
@TestRail(CaseName="Case name in TestRail")
@Test
public void test(){
    
}

License


This project is licensed under Apache License, Version 2.0.

testrailintegrations's People

Contributors

vladislavivanovqa avatar

Stargazers

 avatar

Forkers

madhurichalam

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.