Search in sources :

Example 21 with BeforeTest

use of org.testng.annotations.BeforeTest in project OpenAM by OpenRock.

the class JwtAttributeMapperTest method initialize.

@BeforeTest
public void initialize() {
    jwtMappings = new HashMap<String, Object>();
    jwtMappings.put(SUB, SUBJECT_VALUE);
    jwtMappings.put(ISS, ISSUER);
    jwtMappings.put(EMAIL, EMAIL_VALUE);
    attributeMappings = new HashMap<String, String>();
    attributeMappings.put(SUB, UID);
    attributeMappings.put(EMAIL, AM_EMAIL);
    claimsSet = new JwtClaimsSet(jwtMappings);
    defaultPrincipalMapper = new JwtAttributeMapper("uid", "prefix-");
}
Also used : JwtClaimsSet(org.forgerock.json.jose.jwt.JwtClaimsSet) BeforeTest(org.testng.annotations.BeforeTest)

Example 22 with BeforeTest

use of org.testng.annotations.BeforeTest in project incubator-atlas by apache.

the class FieldMappingTest method beforeTest.

@BeforeTest
public void beforeTest() throws Exception {
    TypeSystem typeSystem = TypeSystem.getInstance();
    typeSystem.reset();
}
Also used : TypeSystem(org.apache.atlas.typesystem.types.TypeSystem) BeforeTest(org.testng.annotations.BeforeTest)

Example 23 with BeforeTest

use of org.testng.annotations.BeforeTest in project incubator-atlas by apache.

the class NotificationHookConsumerKafkaTest method setup.

@BeforeTest
public void setup() throws AtlasException, InterruptedException, AtlasBaseException {
    MockitoAnnotations.initMocks(this);
    AtlasType mockType = mock(AtlasType.class);
    when(typeRegistry.getType(anyString())).thenReturn(mockType);
    AtlasEntity.AtlasEntitiesWithExtInfo mockEntity = mock(AtlasEntity.AtlasEntitiesWithExtInfo.class);
    when(instanceConverter.toAtlasEntities(anyList())).thenReturn(mockEntity);
    kafkaNotification = startKafkaServer();
}
Also used : AtlasEntity(org.apache.atlas.model.instance.AtlasEntity) AtlasType(org.apache.atlas.type.AtlasType) BeforeTest(org.testng.annotations.BeforeTest)

Example 24 with BeforeTest

use of org.testng.annotations.BeforeTest in project jetcd by coreos.

the class MaintenanceUnitTest method setUp.

@BeforeTest
public void setUp() throws AuthFailedException, ConnectException, IOException {
    String uniqueServerName = "fake server for " + getClass();
    fakeServer = InProcessServerBuilder.forName(uniqueServerName).fallbackHandlerRegistry(serviceRegistry).directExecutor().build().start();
    maintenanceCli = new MaintenanceImpl(InProcessChannelBuilder.forName(uniqueServerName).directExecutor().build(), Optional.empty());
    MaintenanceImplBase base = this.defaultBase(responseObserverRef);
    serviceRegistry.addService(base);
}
Also used : MaintenanceImplBase(com.coreos.jetcd.api.MaintenanceGrpc.MaintenanceImplBase) ByteString(com.google.protobuf.ByteString) BeforeTest(org.testng.annotations.BeforeTest)

Example 25 with BeforeTest

use of org.testng.annotations.BeforeTest in project jetcd by coreos.

the class KVTest method setUp.

@BeforeTest
public void setUp() throws Exception {
    test = new Assertion();
    Client client = ClientBuilder.newBuilder().endpoints("http://localhost:2379").build();
    kvClient = client.getKVClient();
}
Also used : Assertion(org.testng.asserts.Assertion) BeforeTest(org.testng.annotations.BeforeTest)

Aggregations

BeforeTest (org.testng.annotations.BeforeTest)80 HashMap (java.util.HashMap)8 CommandManager (com.sun.identity.cli.CommandManager)6 Path (java.nio.file.Path)6 File (java.io.File)5 Injector (com.google.inject.Injector)4 PinotHelixResourceManager (com.linkedin.pinot.controller.helix.core.PinotHelixResourceManager)4 Series (com.axibase.tsd.api.model.series.Series)3 AbstractTableConfig (com.linkedin.pinot.common.config.AbstractTableConfig)3 ArrayList (java.util.ArrayList)3 Parameters (org.testng.annotations.Parameters)3 SSOException (com.iplanet.sso.SSOException)2 Schema (com.linkedin.pinot.common.data.Schema)2 SegmentGeneratorConfig (com.linkedin.pinot.core.indexsegment.generator.SegmentGeneratorConfig)2 SegmentIndexCreationDriver (com.linkedin.pinot.core.segment.creator.SegmentIndexCreationDriver)2 SegmentIndexCreationDriverImpl (com.linkedin.pinot.core.segment.creator.impl.SegmentIndexCreationDriverImpl)2 ThirdEyeConfigProperties (com.linkedin.thirdeye.hadoop.config.ThirdEyeConfigProperties)2 ODatabaseDocumentTx (com.orientechnologies.orient.core.db.document.ODatabaseDocumentTx)2 OrganizationConfigManager (com.sun.identity.sm.OrganizationConfigManager)2 SMSException (com.sun.identity.sm.SMSException)2