Package org.apache.hadoop.hbase
Class TableNameTestExtension
java.lang.Object
org.apache.hadoop.hbase.TableNameTestExtension
- All Implemented Interfaces:
org.junit.jupiter.api.extension.BeforeEachCallback,org.junit.jupiter.api.extension.Extension
public class TableNameTestExtension
extends Object
implements org.junit.jupiter.api.extension.BeforeEachCallback
Returns a
TableName based on currently running test method name.-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidbeforeEach(org.junit.jupiter.api.extension.ExtensionContext context) static StringcleanUpTestName(String methodName) Helper to handle parameterized method names.org.apache.hadoop.hbase.TableName
-
Field Details
-
tableName
-
-
Constructor Details
-
TableNameTestExtension
public TableNameTestExtension()
-
-
Method Details
-
cleanUpTestName
Helper to handle parameterized method names. Unlike regular test methods, parameterized method names look like 'foo[x]'. This is problematic for tests that use this name for HBase tables. This helper strips out the parameter suffixes.- Returns:
- current test method name without parameterized suffixes.
-
getTableName
-
beforeEach
- Specified by:
beforeEachin interfaceorg.junit.jupiter.api.extension.BeforeEachCallback
-