8000 Test actual, not declared behaviour by pzygielo · Pull Request #160 · eclipse-ee4j/orb · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Test actual, not declared behaviour #160

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Aug 12, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
/*
* Copyright (c) 2018, 2020 Oracle and/or its affiliates.
* Copyright (c) 2024 Contributors to the Eclipse Foundation. All rights reserved.
*
* This program and the accompanying materials are made available under the
* terms of the Eclipse Public License v. 2.0 which is available at
Expand Down Expand Up @@ -30,8 +31,6 @@
import javax.annotation.processing.Messager;
import javax.annotation.processing.ProcessingEnvironment;
import javax.annotation.processing.RoundEnvironment;
import javax.annotation.processing.SupportedAnnotationTypes;
import javax.annotation.processing.SupportedSourceVersion;
import javax.lang.model.SourceVersion;
import javax.lang.model.element.Element;
import javax.lang.model.element.Name;
Expand Down Expand Up @@ -77,20 +76,17 @@ public void setUp() throws Exception {

@Test
public void processor_supportsExceptionWrapperAnnotation() {
SupportedAnnotationTypes annotation = ExceptionWrapperProcessor.class.getAnnotation(SupportedAnnotationTypes.class);
assertTrue(Arrays.asList(annotation.value()).contains(ExceptionWrapper.class.getName()));
assertTrue(processor.getSupportedAnnotationTypes().contains(ExceptionWrapper.class.getName()));
}

@Test
public void processor_supportsMessageAnnotation() {
SupportedAnnotationTypes annotation = ExceptionWrapperProcessor.class.getAnnotation(SupportedAnnotationTypes.class);
assertTrue(Arrays.asList(annotation.value()).contains(Message.class.getName()));
assertTrue(processor.getSupportedAnnotationTypes().contains(Message.class.getName()));
}

@Test
public void process_supportsSourceVersion8() {
SupportedSourceVersion annotation = ExceptionWrapperProcessor.class.getAnnotation(SupportedSourceVersion.class);
assertEquals(SourceVersion.RELEASE_8, annotation.value());
assertEquals(SourceVersion.RELEASE_8, processor.getSupportedSourceVersion());
}

@Test
Expand Down Expand Up @@ -332,7 +328,7 @@ public Types getTypeUtils() {

@Override
public SourceVersion getSourceVersion() {
return null;
return SourceVersion.RELEASE_8;
}

@Override
Expand Down
0