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

Simplify acceptance tests #106

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

jphalip
Copy link
Collaborator

@jphalip jphalip commented Sep 15, 2023

Use default values for some environment variables to make it easier to run the tests

Use default values for some environment variables to make it easier to run the tests
@@ -46,7 +46,7 @@ public class TestUtils {
public static final String MANAGED_TEST_TABLE_NAME = "managed_test";
public static final String FIELD_TIME_PARTITIONED_TABLE_NAME = "field_time_partitioned";
public static final String INGESTION_TIME_PARTITIONED_TABLE_NAME = "ingestion_time_partitioned";
public static final String TEST_BUCKET_ENV_VAR = "TEST_BUCKET";
public static final String INTEGRATION_BUCKET_ENV_VAR = "INTEGRATION_BUCKET";
Copy link
Collaborator

Choose a reason for hiding this comment

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

You might want to document this env variable in README with its default value.

Preconditions.checkNotNull(
System.getenv("GOOGLE_CLOUD_PROJECT"),
"Please set the 'GOOGLE_CLOUD_PROJECT' environment variable");
public static final String ACCEPTANCE_BUCKET_ENV_VAR = "ACCEPTANCE_BUCKET";
Copy link
Collaborator

Choose a reason for hiding this comment

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

ditto.

@@ -773,19 +777,16 @@ You must use Java version 8, as it's the version that Hive itself uses. Make sur

Acceptance tests create Dataproc clusters with the connector and run jobs to verify it.

The following environment variables must be set and **exported** first.

* `GOOGLE_APPLICATION_CREDENTIALS` - the full path to a credentials JSON, either a service account or the result of a
Copy link
Collaborator

Choose a reason for hiding this comment

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

Why are they removed?

@@ -711,7 +715,7 @@ export PROJECT=my-gcp-project
export BIGLAKE_LOCATION=us
export BIGLAKE_REGION=us-central1
export BIGLAKE_CONNECTION=hive-integration-tests
export BIGLAKE_BUCKET=${USER}-biglake-test
export BIGLAKE_BUCKET=${PROJECT}-biglake-tests
Copy link
Collaborator

Choose a reason for hiding this comment

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

Many projects have a : in their names, e.g., google.com:project, which makes this default bucket name invalid. At least, consider automatically converting : to _ or - here.

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