Skip to content

Commit

Permalink
Fix fabric8io#1996: Added module-info.java files for different module…
Browse files Browse the repository at this point in the history
…s in project
  • Loading branch information
rohanKanojia committed Apr 4, 2020
1 parent 555c379 commit f74cd1a
Show file tree
Hide file tree
Showing 40 changed files with 757 additions and 152 deletions.
25 changes: 25 additions & 0 deletions extensions/knative/annotator/src/main/java/module-info.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
/**
* Copyright (C) 2015 Red Hat, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
module io.fabric8.knative.annotator {
requires io.fabric8.kubernetes.model.common;
requires com.fasterxml.jackson.databind;
requires codemodel;
requires lombok;
requires jsonschema2pojo.core;
requires transform.annotations;
requires builder.annotations;
exports io.fabric8.knative;
}
19 changes: 19 additions & 0 deletions extensions/knative/client/src/main/java/module-info.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
/**
* Copyright (C) 2015 Red Hat, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
module io.fabric8.knative.client {
requires io.fabric8.kubernetes.client;
requires io.fabric8.kubernetes.model;
}
19 changes: 19 additions & 0 deletions extensions/knative/examples/src/main/java/module-info.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
/**
* Copyright (C) 2015 Red Hat, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
module io.fabric8.knative.api.examples {
requires io.fabric8.knative.client;
exports io.fabric8.knative.api.examples;
}
20 changes: 20 additions & 0 deletions extensions/knative/mock/src/main/java/module-info.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
/**
* Copyright (C) 2015 Red Hat, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
module io.fabric8.knative.mock {
requires io.fabric8.kubernetes.server.mock;
requires io.fabric8.knative.client;
exports io.fabric8.knative.mock;
}
22 changes: 22 additions & 0 deletions extensions/knative/model/src/main/java/module-info.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
/**
* Copyright (C) 2015 Red Hat, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
module io.fabric8.knative.api.model {
requires io.fabric8.kubernetes.model;
requires transform.annotations;
requires builder.annotations;
exports io.fabric8.knative.api.model;
exports io.fabric8.knative.serving.v1;
}
20 changes: 20 additions & 0 deletions extensions/knative/tests/src/test/java/module-info.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
/**
* Copyright (C) 2015 Red Hat, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
module io.fabric8.knative.test {
requires io.fabric8.knative.client;
requires io.fabric8.knative.mock;
exports io.fabric8.knative.test.crud;
}
22 changes: 22 additions & 0 deletions extensions/service-catalog/client/src/main/java/module-info.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
/**
* Copyright (C) 2015 Red Hat, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
module io.fabric8.servicecatalog.client {
requires io.fabric8.kubernetes.client;
requires io.fabric8.servicecatalog.api.model;
exports io.fabric8.servicecatalog.client.internal;
exports io.fabric8.servicecatalog.client.handlers;
exports io.fabric8.servicecatalog.client.util;
}
19 changes: 19 additions & 0 deletions extensions/service-catalog/examples/src/main/java/module-info.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
/**
* Copyright (C) 2015 Red Hat, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
module io.fabric8.servicecatalog.examples {
requires io.fabric8.servicecatalog.client;
exports io.fabric8.servicecatalog.examples;
}
20 changes: 20 additions & 0 deletions extensions/service-catalog/mock/src/main/java/module-info.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
/**
* Copyright (C) 2015 Red Hat, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
module io.fabric8.servicecatalog.server.mock {
requires io.fabric8.kubernetes.server.mock;
requires io.fabric8.servicecatalog.client;
exports io.fabric8.servicecatalog.server.mock;
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
/**
* Copyright (C) 2015 Red Hat, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
module io.fabric8.servicecatalog.annotator {
requires io.fabric8.kubernetes.model.common;
requires com.fasterxml.jackson.databind;
requires transform.annotations;
requires builder.annotations;
requires codemodel;
requires lombok;
requires jsonschema2pojo.core;
exports io.fabric8.servicecatalog.annotator;
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
/**
* Copyright (C) 2015 Red Hat, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
module io.fabric8.servicecatalog.api.model {
requires io.fabric8.kubernetes.model;
requires java.annotation;
requires com.fasterxml.jackson.annotation;
requires com.fasterxml.jackson.databind;
requires builder.annotations;

exports io.fabric8.servicecatalog.api.model;
}
20 changes: 20 additions & 0 deletions extensions/service-catalog/tests/src/test/java/module-info.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
/**
* Copyright (C) 2015 Red Hat, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
module io.fabric8.servicecatalog.test {
requires io.fabric8.kubernetes.client;
requires io.fabric8.servicecatalog.server.mock;
exports io.fabric8.servicecatalog.test.crud;
}
19 changes: 19 additions & 0 deletions extensions/tekton/annotator/src/main/java/module-info.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
/**
* Copyright (C) 2015 Red Hat, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
module io.fabric8.tekton.annotator {
requires io.fabric8.kubernetes.model.common;
exports io.fabric8.tekton;
}
22 changes: 22 additions & 0 deletions extensions/tekton/client/src/main/java/module-info.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
/**
* Copyright (C) 2015 Red Hat, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
module io.fabric8.tekton.client {
requires io.fabric8.tekton.model;
requires io.fabric8.kubernetes.client;
exports io.fabric8.tekton.client.internal;
exports io.fabric8.tekton.client.handlers;
exports io.fabric8.tekton.client.util;
}
19 changes: 19 additions & 0 deletions extensions/tekton/examples/src/main/java/module-info.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
/**
* Copyright (C) 2015 Red Hat, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
module io.fabric8.tekton.api.examples {
requires io.fabric8.tekton.client;
exports io.fabric8.tekton.api.examples;
}
20 changes: 20 additions & 0 deletions extensions/tekton/mock/src/main/java/module-info.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
/**
* Copyright (C) 2015 Red Hat, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
module io.fabric8.tekton.mock {
requires io.fabric8.kubernetes.server.mock;
requires io.fabric8.tekton.client;
exports io.fabric8.tekton.mock;
}
21 changes: 21 additions & 0 deletions extensions/tekton/model/src/main/java/module-info.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
/**
* Copyright (C) 2015 Red Hat, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
module io.fabric8.tekton.model {
requires io.fabric8.kubernetes.model;
requires io.fabric8.knative.api.model;
exports io.fabric8.tekton.api.model;
exports io.fabric8.tekton.pipeline.v1alpha1;
}
Original file line number Diff line number Diff line change
Expand Up @@ -31,12 +31,12 @@ public void testArrayOrStringJson() throws IOException {
ObjectMapper mapper = new ObjectMapper();
String json = mapper.writeValueAsString(is);
ArrayOrString is2 = mapper.readValue(json, ArrayOrString.class);
assertEquals(is, is2);
assertEquals(is.getStringVal(), is2.getStringVal());

is = new ArrayOrString(Arrays.asList("a", "b"));
json = mapper.writeValueAsString(is);
is2 = mapper.readValue(json, ArrayOrString.class);
assertEquals(is, is2);
assertEquals(is.getArrayVal(), is2.getArrayVal());
}

}

0 comments on commit f74cd1a

Please sign in to comment.