All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.specsy.junit5.NestedTestDescriptor Maven / Gradle / Ivy

// Copyright © 2010-2016, Esko Luontola 
// This software is released under the Apache License 2.0.
// The license text is at http://www.apache.org/licenses/LICENSE-2.0

package org.specsy.junit5;

import fi.jumi.api.drivers.TestId;
import org.junit.platform.engine.TestDescriptor;
import org.junit.platform.engine.support.descriptor.AbstractTestDescriptor;

public class NestedTestDescriptor extends AbstractTestDescriptor {

    public static final String SEGMENT_TYPE = "nested";

    private final TestId testId;

    public NestedTestDescriptor(TestDescriptor parent, TestId testId, String name) {
        super(parent.getUniqueId().append(SEGMENT_TYPE, String.valueOf(testId.getIndex())), name);
        this.testId = testId;
    }

    public TestId getTestId() {
        return testId;
    }

    @Override
    public boolean isTest() {
        return true;
    }

    @Override
    public boolean isContainer() {
        return true;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy