Fix CDI package names (#7715)
* Fix beans.xsd location for JavaEE 7 * Fix cdi2observers package names
This commit is contained in:
parent
823bc9d4b0
commit
da1db18bc9
|
@ -1,6 +1,7 @@
|
||||||
package com.baeldung.cdi.cdi2observers.application;
|
package com.baeldung.cdi2observers.application;
|
||||||
|
|
||||||
|
import com.baeldung.cdi2observers.events.ExampleEvent;
|
||||||
|
|
||||||
import com.baeldung.cdi.cdi2observers.events.ExampleEvent;
|
|
||||||
import javax.enterprise.inject.se.SeContainer;
|
import javax.enterprise.inject.se.SeContainer;
|
||||||
import javax.enterprise.inject.se.SeContainerInitializer;
|
import javax.enterprise.inject.se.SeContainerInitializer;
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
package com.baeldung.cdi.cdi2observers.events;
|
package com.baeldung.cdi2observers.events;
|
||||||
|
|
||||||
public class ExampleEvent {
|
public class ExampleEvent {
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
package com.baeldung.cdi.cdi2observers.events;
|
package com.baeldung.cdi2observers.events;
|
||||||
|
|
||||||
import javax.enterprise.event.Event;
|
import javax.enterprise.event.Event;
|
||||||
import javax.inject.Inject;
|
import javax.inject.Inject;
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
package com.baeldung.cdi.cdi2observers.observers;
|
package com.baeldung.cdi2observers.observers;
|
||||||
|
|
||||||
|
import com.baeldung.cdi2observers.events.ExampleEvent;
|
||||||
|
|
||||||
import com.baeldung.cdi.cdi2observers.events.ExampleEvent;
|
|
||||||
import javax.annotation.Priority;
|
import javax.annotation.Priority;
|
||||||
import javax.enterprise.event.Observes;
|
import javax.enterprise.event.Observes;
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
package com.baeldung.cdi.cdi2observers.observers;
|
package com.baeldung.cdi2observers.observers;
|
||||||
|
|
||||||
import com.baeldung.cdi.cdi2observers.events.ExampleEvent;
|
import com.baeldung.cdi2observers.events.ExampleEvent;
|
||||||
import com.baeldung.cdi.cdi2observers.services.TextService;
|
import com.baeldung.cdi2observers.services.TextService;
|
||||||
import javax.annotation.Priority;
|
import javax.annotation.Priority;
|
||||||
import javax.enterprise.event.Observes;
|
import javax.enterprise.event.Observes;
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
package com.baeldung.cdi.cdi2observers.services;
|
package com.baeldung.cdi2observers.services;
|
||||||
|
|
||||||
public class TextService {
|
public class TextService {
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,8 @@
|
||||||
<beans xmlns="http://java.sun.com/xml/ns/javaee"
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<beans xmlns="http://xmlns.jcp.org/xml/ns/javaee"
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
|
xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee http://xmlns.jcp.org/xml/ns/javaee/beans_1_1.xsd"
|
||||||
http://java.sun.com/xml/ns/javaee/beans_1_2.xsd">
|
bean-discovery-mode="all">
|
||||||
<interceptors>
|
<interceptors>
|
||||||
<class>com.baeldung.interceptor.AuditedInterceptor</class>
|
<class>com.baeldung.interceptor.AuditedInterceptor</class>
|
||||||
</interceptors>
|
</interceptors>
|
||||||
|
|
|
@ -1,9 +1,10 @@
|
||||||
package com.baeldung.cdi.cdi2observers.tests;
|
package com.baeldung.test.cdi2observers.tests;
|
||||||
|
|
||||||
import com.baeldung.cdi.cdi2observers.services.TextService;
|
import com.baeldung.cdi2observers.services.TextService;
|
||||||
import static org.assertj.core.api.Assertions.assertThat;
|
|
||||||
import org.junit.Test;
|
import org.junit.Test;
|
||||||
|
|
||||||
|
import static org.assertj.core.api.Assertions.assertThat;
|
||||||
|
|
||||||
public class TextServiceUnitTest {
|
public class TextServiceUnitTest {
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
|
|
@ -6,7 +6,6 @@ import static org.assertj.core.api.Assertions.assertThat;
|
||||||
import org.junit.Test;
|
import org.junit.Test;
|
||||||
|
|
||||||
public class TimeLoggerFactoryUnitTest {
|
public class TimeLoggerFactoryUnitTest {
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void givenTimeLoggerFactory_whenCalledgetTimeLogger_thenOneAssertion() {
|
public void givenTimeLoggerFactory_whenCalledgetTimeLogger_thenOneAssertion() {
|
||||||
TimeLoggerFactory timeLoggerFactory = new TimeLoggerFactory();
|
TimeLoggerFactory timeLoggerFactory = new TimeLoggerFactory();
|
||||||
|
|
Loading…
Reference in New Issue