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

Update integration tests to use new approach #262

Conversation

paulpalamarchuk
Copy link
Contributor

@paulpalamarchuk paulpalamarchuk commented Sep 18, 2019

@paulpalamarchuk
Copy link
Contributor Author

Int test that failed on CI, run locally:
kitchen_deploy-service-local
kitchen_node-pool-local

@aaron-lane aaron-lane added the enhancement New feature or request label Sep 19, 2019
@paulpalamarchuk paulpalamarchuk force-pushed the move_tests_to_cloudbuild branch 4 times, most recently from c13d1b6 to 80c5dee Compare September 19, 2019 16:08
ingwarr
ingwarr previously approved these changes Sep 19, 2019
CHANGELOG.md Outdated Show resolved Hide resolved

locals {
int_required_roles = [
"roles/owner",
Copy link
Contributor

Choose a reason for hiding this comment

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

I prefer to do not use wide rolesthat includes other permissions like comute.viewer etc

Copy link
Contributor

@ingwarr ingwarr Sep 21, 2019

Choose a reason for hiding this comment

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

But it works, I think minimization of permissions is next low-priority task

Copy link
Contributor Author

Choose a reason for hiding this comment

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

role removed

Copy link
Contributor

Choose a reason for hiding this comment

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

It's not removed. Please either fix it or say why you chose not to.

ingwarr
ingwarr previously approved these changes Sep 21, 2019
ingwarr
ingwarr previously approved these changes Sep 23, 2019
kopachevsky
kopachevsky previously approved these changes Sep 24, 2019
ingwarr
ingwarr previously approved these changes Sep 24, 2019
@morgante morgante self-assigned this Sep 30, 2019
CONTRIBUTING.md Outdated Show resolved Hide resolved
Makefile Outdated
docker run --rm -it \
-v $(CURDIR):/workspace \
$(REGISTRY_URL)/${DOCKER_IMAGE_DEVELOPER_TOOLS}:${DOCKER_TAG_VERSION_DEVELOPER_TOOLS} \
/bin/bash -c 'source /usr/local/bin/task_helper_functions.sh && /workspace/helpers/generate.sh && generate'
Copy link
Contributor

Choose a reason for hiding this comment

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

Do not source an extra file. This is not necessary, as I explained in chat.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Removed

# limitations under the License.

steps:
- id: 'lint-pull-image'
Copy link
Contributor

Choose a reason for hiding this comment

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

We don't want to do this. @aaron-lane I know you had suggested it but I think it's a bad idea. If we split them out like this, we'll have to copy every linting step into every repo and maintain it separately.

waitFor: ['lint-pull-image']
- id: 'lint-terraform'
name: 'gcr.io/cloud-foundation-cicd/$_DOCKER_IMAGE_DEVELOPER_TOOLS:$_DOCKER_TAG_VERSION_DEVELOPER_TOOLS'
args: ['/bin/bash', '-c', 'source /usr/local/bin/task_helper_functions.sh && source /workspace/helpers/generate.sh && check_terraform']
Copy link
Contributor

Choose a reason for hiding this comment

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

Don't source custom file.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

removed

helpers/generate.sh Outdated Show resolved Hide resolved
./helpers/generate_modules/generate_modules.py
}

function check_generate() {
Copy link
Contributor

Choose a reason for hiding this comment

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

Why was this function rewritten to be different from master? I'd like an explanation of why these changes were done.

Copy link
Contributor Author

@paulpalamarchuk paulpalamarchuk Oct 1, 2019

Choose a reason for hiding this comment

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

  1. At the moment we don't have function to generate submodules from autorgen directory in docker-image.
  2. I've changed function find_files (added path ./autogen) to exclude that dir from terraform format checks


locals {
int_required_roles = [
"roles/owner",
Copy link
Contributor

Choose a reason for hiding this comment

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

It's not removed. Please either fix it or say why you chose not to.

test/setup/make_source.sh Outdated Show resolved Hide resolved
test/setup/make_source.sh Show resolved Hide resolved
@paulpalamarchuk paulpalamarchuk force-pushed the move_tests_to_cloudbuild branch 3 times, most recently from 1556a25 to 40a918e Compare October 1, 2019 15:02
/workspace/helpers/generate_modules/generate_modules.py
}

function check_generate() {
Copy link
Contributor

Choose a reason for hiding this comment

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

@paulpalamarchuk I still don't understand why this differs so much from master. It's not clear to me why this would need to be different from the logic we already have [written](Right, what I don't understand is why the logic for this function is so different from what's currently implemented on master. Instead of needing to ).

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@morgante I changed this function to avoid errors on CI, in case of using git-diff to compare files. Error: fatal: not a git repository (or any parent up to mount point /)

Copy link
Contributor

Choose a reason for hiding this comment

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

Ok it's workable then.

 * Fix terraform-google-modules#245
 * Fixed lint-tests
 * Backwards compatibility of the `generate` function
 * Disabled kitchen test `stub-domains-private-local` (issue terraform-google-modules#264)
@morgante morgante merged commit 81eb717 into terraform-google-modules:master Oct 2, 2019
CPL-markus pushed a commit to WALTER-GROUP/terraform-google-kubernetes-engine that referenced this pull request Jul 15, 2024
…move_tests_to_cloudbuild

Update integration tests to use new approach
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Migrate repository to new development and CI process
5 participants