-
Notifications
You must be signed in to change notification settings - Fork 3.7k
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
Enable quidem shadowing for decoupled testcases #16431
Merged
kgyrtkirk
merged 11 commits into
apache:master
from
kgyrtkirk:quidem-runner-extension-submit
May 23, 2024
Merged
Changes from 6 commits
Commits
Show all changes
11 commits
Select commit
Hold shift + click to select a range
e13d560
Enable quidem shadowing for decoupled testcases
kgyrtkirk e36c46a
fix import
kgyrtkirk 3132c12
remove unnecessary \\
kgyrtkirk 9578953
Merge remote-tracking branch 'apache/master' into quidem-runner-exten…
kgyrtkirk b7b73fa
fix context key order
kgyrtkirk 94f9386
Merge remote-tracking branch 'apache/master' into quidem-runner-exten…
kgyrtkirk 652cc20
use lower_camel for config names
kgyrtkirk 453c11f
update exceptions;test output
kgyrtkirk ecdcd0f
Merge remote-tracking branch 'apache/master' into quidem-runner-exten…
kgyrtkirk ad64784
fix test expectation
kgyrtkirk e4ca09d
Merge remote-tracking branch 'apache/master' into quidem-runner-exten…
kgyrtkirk File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
41 changes: 41 additions & 0 deletions
41
sql/src/test/java/org/apache/druid/quidem/DruidQTestInfo.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
/* | ||
* Licensed to the Apache Software Foundation (ASF) under one | ||
* or more contributor license agreements. See the NOTICE file | ||
* distributed with this work for additional information | ||
* regarding copyright ownership. The ASF licenses this file | ||
* to you 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. | ||
*/ | ||
|
||
package org.apache.druid.quidem; | ||
|
||
import java.io.File; | ||
|
||
public class DruidQTestInfo | ||
{ | ||
public final File caseDir; | ||
public final String testName; | ||
public final String comment; | ||
|
||
public DruidQTestInfo(File caseDir, String testName, String comment) | ||
{ | ||
this.caseDir = caseDir; | ||
this.testName = testName; | ||
this.comment = comment; | ||
} | ||
|
||
public File getIQFile() | ||
{ | ||
return new File(caseDir, testName + ".iq"); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This error message is just dumping the maps, but it's unclear what you are supposed to do with that? Who is this error message for? Is the expectation that the maps have the same keys? Which one had a bad key?
Generally speaking, can you make this a
DruidException
with relevant persona (is this something a user will see?), explain a bit more about what is expected and what the person is supposed to do?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
let me share a small back-story for this:
BaseCalciteQueryTest#testBuilder
someone can specifyqueryContext
andplannerConfig
as well - however most of theplannerContext
settings can be achieved by settingqueryContext
variablesplannerConfig
inqueryContext
formPlannerConfig
as an implicit settings class which is implicitly defined by thequeryContext
settingsthis method was just needed in that process - I've change the exception message to
and used
DruidException.defensive
instead; as only a developer could fix this issue.