Uploaded image for project: 'OpenMRS Core'
  1. OpenMRS Core
  2. TRUNK-4051

In context-sensitive tests, @SkipBaseSetup annotation is not inherited from superclasses

    XMLWordPrintable

Details

    Description

      I would like to be able to do something like this:

      @SkipBaseSetup
      public abstract class BaseMirebalaisReportTest extends BaseModuleContextSensitiveTest {
      
          @Autowired
          protected ReportDefinitionService reportDefinitionService;
      
          @Before
          public void setup() throws Exception {
              executeDataSet("org/openmrs/module/mirebalaisreports/coreMetadata.xml");
              authenticate();
          }
      
      }
      

      However when I do a concrete implementation of this class, our test framework code doesn't notice the @SkipBaseSetup annotation on the abstract base class, and I have to add the annotation to the subclass as well.

      We need to fix org.openmrs.test.SkipBaseSetupAnnotationExecutionListener so that it also looks at superclasses of the test class for the SkipBaseSetup annotation.

      Gliffy Diagrams

        Attachments

          Activity

            People

              namefilip Filip Spiridonov
              darius Darius Jazayeri
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - 4 hours
                  4h
                  Remaining:
                  Time Spent - 30 minutes Remaining Estimate - 3 hours, 30 minutes
                  3h 30m
                  Logged:
                  Time Spent - 30 minutes Remaining Estimate - 3 hours, 30 minutes
                  30m