Move src to spring-testing module (#6375)

This commit is contained in:
Juan Moreno
2019-02-21 00:50:34 -03:00
committed by KevinGilmore
parent 6f71b21996
commit f50fc2a9fd
6 changed files with 14 additions and 7 deletions
@@ -1,11 +0,0 @@
package com.baeldung.config;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;
import org.springframework.scheduling.annotation.EnableScheduling;
@Configuration
@EnableScheduling
@ComponentScan("com.baeldung.scheduled")
public class ScheduledConfig {
}
@@ -1,20 +0,0 @@
package com.baeldung.scheduled;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;
import java.util.concurrent.atomic.AtomicInteger;
@Component
public class Counter {
private final AtomicInteger count = new AtomicInteger(0);
@Scheduled(fixedDelay = 5)
public void scheduled() {
this.count.incrementAndGet();
}
public int getInvocationCount() {
return this.count.get();
}
}