Skip to content
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

Sync CESQL tck tests #603

Merged
merged 1 commit into from
Jan 31, 2024
Merged

Conversation

Cali0707
Copy link
Contributor

@Cali0707 Cali0707 commented Jan 30, 2024

I recently realized that the tck tests for CESQL are not up to date with the new ones added in the spec repo. This PR just copies those changes over into sdk-java, and registers the new test file.

cc @duglin @pierDipi

Signed-off-by: Calum Murray <cmurray@redhat.com>
@pierDipi pierDipi merged commit 7b9d020 into cloudevents:main Jan 31, 2024
5 checks passed
Copy link
Member

@pierDipi pierDipi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I just realized that the tests failures are hidden, and the CI doesn't fail

If you apply this diff you will get errors in the tests:

diff --git a/sql/src/test/java/io/cloudevents/sql/TCKTestSuite.java b/sql/src/test/java/io/cloudevents/sql/TCKTestSuite.java
index d48b7a3..82c2997 100644
--- a/sql/src/test/java/io/cloudevents/sql/TCKTestSuite.java
+++ b/sql/src/test/java/io/cloudevents/sql/TCKTestSuite.java
@@ -124,8 +124,7 @@ public class TCKTestSuite {
                 try {
                     return mapper.readValue(this.getClass().getResource(fileName), TestSuiteModel.class);
                 } catch (IOException e) {
-                    e.printStackTrace();
-                    return null;
+                    throw new RuntimeException(fileName, e);
                 }
             })
             .filter(Objects::nonNull)

@pierDipi
Copy link
Member

Even after fixing the expresion type in the sql/src/test/resources/tck/subscriptions_api_recreations.yaml file, there are tests failures

@Cali0707
Copy link
Contributor Author

Even after fixing the expresion type in the sql/src/test/resources/tck/subscriptions_api_recreations.yaml file, there are tests failures

As far as I can tell, the test failure is do to a mistake in the actual tck test case, where it is expecting the wrong result. I'll open a PR to spec with the fixes to the tck tests and then pull those changes in here

touchkey pushed a commit to touchkey/sdk-java that referenced this pull request Feb 15, 2024
Signed-off-by: Calum Murray <cmurray@redhat.com>
Signed-off-by: vbhat6 <vinayas_bhat@intuit.com>
@pierDipi pierDipi mentioned this pull request Jun 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants