github.com/hernad/nomad@v1.6.112/e2e/framework/interfaces.go (about)

     1  // Copyright (c) HashiCorp, Inc.
     2  // SPDX-License-Identifier: MPL-2.0
     3  
     4  package framework
     5  
     6  // TestCase is the interface which an E2E test case implements.
     7  // It is not meant to be implemented directly, instead the struct should embed
     8  // the 'framework.TC' struct
     9  //
    10  // Deprecated: no longer use e2e/framework for new tests; see TestExample for new e2e test structure.
    11  type TestCase interface {
    12  	internalTestCase
    13  
    14  	Name() string
    15  }
    16  
    17  type internalTestCase interface {
    18  	setClusterInfo(*ClusterInfo)
    19  }
    20  
    21  // BeforeAllTests is used to define a method to be called before the execution
    22  // of all tests.
    23  //
    24  // Deprecated: no longer use e2e/framework for new tests; see TestExample for new e2e test structure.
    25  type BeforeAllTests interface {
    26  	BeforeAll(*F)
    27  }
    28  
    29  // AfterAllTests is used to define a method to be called after the execution of
    30  // all tests.
    31  //
    32  // Deprecated: no longer use e2e/framework for new tests; see TestExample for new e2e test structure.
    33  type AfterAllTests interface {
    34  	AfterAll(*F)
    35  }
    36  
    37  // BeforeEachTest is used to define a method to be called before each test.
    38  //
    39  // Deprecated: no longer use e2e/framework for new tests; see TestExample for new e2e test structure.
    40  type BeforeEachTest interface {
    41  	BeforeEach(*F)
    42  }
    43  
    44  // AfterEachTest is used to define a method to be called after each test.
    45  //
    46  // Deprecated: no longer use e2e/framework for new tests; see TestExample for new e2e test structure.
    47  type AfterEachTest interface {
    48  	AfterEach(*F)
    49  }