How to write junit for the below code | Community
Skip to main content
djohn98390536
November 25, 2024
Solved

How to write junit for the below code

  • November 25, 2024
  • 1 reply
  • 478 views

import org.osgi.service.component.annotations.Component;
import org.apache.sling.event.jobs.Job;
import org.apache.sling.event.jobs.consumer.JobConsumer;

@8220494(service=JobConsumer.class, property= {
JobConsumer.PROPERTY_TOPICS + "=my/special/jobtopic"
})
public class MyJobConsumer implements JobConsumer {

public JobResult process(final Job job) {
String path = job.getProperty("path");
return JobResult.OK;
}
}

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.

1 reply

EstebanBustamante
Community Advisor and Adobe Champion
EstebanBustamanteCommunity Advisor and Adobe ChampionAccepted solution
Community Advisor and Adobe Champion
November 26, 2024