Skip to content

Proposal: TestScope helper #28

@678098

Description

@678098

Is there an existing proposal for this?

  • I have searched the existing proposals

Is your feature request related to a problem?

We have a lot of lines like this:

        logger.info("==============================================");
        logger.info("BEGIN Testing SessionIT queue flush down.");
        logger.info("==============================================");

We might want to standartize this to avoid errors.

Describe the solution you'd like

I propose to make a helper class for this, the usage should look like this:

class ComponentIT {

  public testStress() {

    TestScope scope = new TestScope(this, "testStress");
    // should log:
    // ==================================
    // #BEGIN_TEST ComponentIT testStress
    // ==================================

    scope.step("Open session");
    // should log:
    // #STEP 1. Open session

    scope.step("Close session");
    // should log:
    // #STEP 2. Close session

    scope.end();
    // should log:
    // ==========================================
    // #END_TEST ComponentIT testStress - 13.21 s
    // ==========================================

  }

}

Alternatives you considered

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions