Skip to content

Commit

Permalink
Merge pull request #127 from com-pas/develop
Browse files Browse the repository at this point in the history
New release
  • Loading branch information
Dennis Labordus authored Oct 14, 2021
2 parents c39d5ab + 2539dc8 commit 8e3136a
Show file tree
Hide file tree
Showing 5 changed files with 43 additions and 12 deletions.
1 change: 0 additions & 1 deletion app/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,6 @@ SPDX-License-Identifier: Apache-2.0
<quarkus.package.type>native</quarkus.package.type>
<!-- Allows for creating a Linux executable without GraalVM being installed -->
<quarkus.native.container-build>true</quarkus.native.container-build>
<quarkus.native.additional-build-args>-H:ReflectionConfigurationFiles=reflection-config.json</quarkus.native.additional-build-args>
</properties>

<build>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
// SPDX-FileCopyrightText: 2021 Alliander N.V.
//
// SPDX-License-Identifier: Apache-2.0
package org.lfenergy.compas.scl.data.rest;

import io.quarkus.runtime.annotations.RegisterForReflection;

/**
* Configure class for Quarkus Native Build to be included.
*/
@RegisterForReflection(
targets = {
org.lfenergy.compas.core.jaxrs.model.ErrorMessage.class,
org.lfenergy.compas.core.jaxrs.model.ErrorResponse.class,
org.lfenergy.compas.scl.data.model.SclMetaInfo.class,
org.lfenergy.compas.scl.data.model.ObjectFactory.class
})
public class CompasReflectionConfiguration {
}
7 changes: 0 additions & 7 deletions app/src/main/resources/reflection-config.json

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
// SPDX-FileCopyrightText: 2021 Alliander N.V.
//
// SPDX-License-Identifier: Apache-2.0
package org.lfenergy.compas.scl.data.rest;

import org.junit.jupiter.api.Test;

import static org.junit.jupiter.api.Assertions.assertNotNull;

class CompasReflectionConfigurationTest {
@Test
void constructor_WhenCalled_ThenNoExceptions() {
var config = new CompasReflectionConfiguration();
assertNotNull(config);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -8,20 +8,24 @@
import static org.junit.jupiter.api.Assertions.assertNotNull;

class CompasSclDataServiceConfigurationTest {
private CompasSclDataServiceConfiguration configuration = new CompasSclDataServiceConfiguration();
@Test
void constructor_WhenCalled_ThenNoExceptions() {
var config = new CompasSclDataServiceConfiguration();
assertNotNull(config);
}

@Test
void createElementConverter_WhenCalled_ThenObjectReturned() {
assertNotNull(configuration.createElementConverter());
assertNotNull(new CompasSclDataServiceConfiguration().createElementConverter());
}

@Test
void creatSclElementProcessor_WhenCalled_ThenObjectReturned() {
assertNotNull(configuration.creatSclElementProcessor());
assertNotNull(new CompasSclDataServiceConfiguration().creatSclElementProcessor());
}

@Test
void createSclDataModelMarshaller_WhenCalled_ThenObjectReturned() {
assertNotNull(configuration.createSclDataModelMarshaller());
assertNotNull(new CompasSclDataServiceConfiguration().createSclDataModelMarshaller());
}
}

0 comments on commit 8e3136a

Please sign in to comment.