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

Pass FEATURE_GATES flag to e2e tests #1445

Merged
merged 9 commits into from Apr 21, 2020

Conversation

akremsa
Copy link
Contributor

@akremsa akremsa commented Apr 2, 2020

This PR is a part of #1411 and allows to turn on\off feature gates behaviour in e2e tests.

Also updated some tests introduced in #1396

Copy link
Collaborator

@aLekSer aLekSer left a comment

Choose a reason for hiding this comment

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

Now we can switch between Features to create 2 separate E2E tests CI pipelines.

test/e2e/main_test.go Outdated Show resolved Hide resolved
@agones-bot
Copy link
Collaborator

Build Failed 😱

Build Id: a8f9205d-0f00-4f15-83b0-5badfca7a6fe

To get permission to view the Cloud Build view, join the agones-discuss Google Group.

@agones-bot
Copy link
Collaborator

Build Failed 😱

Build Id: acfb6bfa-0773-4a9a-b605-cd68b77c1387

To get permission to view the Cloud Build view, join the agones-discuss Google Group.

@akremsa akremsa force-pushed the exclude-featuregates branch 2 times, most recently from 32409b0 to 767d5c4 Compare April 2, 2020 14:20
@agones-bot
Copy link
Collaborator

Build Failed 😱

Build Id: 702814fd-dc04-4075-a53a-6b1fabafc073

To get permission to view the Cloud Build view, join the agones-discuss Google Group.

@agones-bot
Copy link
Collaborator

Build Failed 😱

Build Id: 0ccfd2a5-24b4-415f-99e7-0fc79090a22c

To get permission to view the Cloud Build view, join the agones-discuss Google Group.

@aLekSer
Copy link
Collaborator

aLekSer commented Apr 2, 2020

I think we need to update build/e2e-image/e2e.sh
Or add default parameter :

test-e2e: FEATURE_GATES ?= "PlayerCount=true&ContainerPort=true"
test-e2e:
	$(MAKE) test-e2e-integration
	$(MAKE) test-e2e-failure

@akremsa
Copy link
Contributor Author

akremsa commented Apr 2, 2020

FEATURE_GATES

Moved FEATURE_GATES the the top of Makefile

@agones-bot
Copy link
Collaborator

Build Succeeded 👏

Build Id: fcc69dc0-b516-4e37-8932-e6d701994537

The following development artifacts have been built, and will exist for the next 30 days:

A preview of the website (the last 30 builds are retained):

To install this version:

  • git fetch https://github.com/GoogleCloudPlatform/agones.git pull/1445/head:pr_1445 && git checkout pr_1445
  • helm install ./install/helm/agones --namespace agones-system --name agones --set agones.image.tag=1.5.0-0b2e3c0

Copy link
Collaborator

@aLekSer aLekSer left a comment

Choose a reason for hiding this comment

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

Now install and test-e2e uses same FeatureGates by default.

test/e2e/main_test.go Outdated Show resolved Hide resolved
@agones-bot
Copy link
Collaborator

Build Succeeded 👏

Build Id: d259f19d-1afa-4c52-ac06-d32695ac3fa6

The following development artifacts have been built, and will exist for the next 30 days:

A preview of the website (the last 30 builds are retained):

To install this version:

  • git fetch https://github.com/GoogleCloudPlatform/agones.git pull/1445/head:pr_1445 && git checkout pr_1445
  • helm install ./install/helm/agones --namespace agones-system --name agones --set agones.image.tag=1.5.0-d9702d6

@agones-bot
Copy link
Collaborator

Build Succeeded 👏

Build Id: f9588e58-98d1-4a79-9c39-7adb4f8c6f0f

The following development artifacts have been built, and will exist for the next 30 days:

A preview of the website (the last 30 builds are retained):

To install this version:

  • git fetch https://github.com/GoogleCloudPlatform/agones.git pull/1445/head:pr_1445 && git checkout pr_1445
  • helm install ./install/helm/agones --namespace agones-system --name agones --set agones.image.tag=1.5.0-8c47647

@aLekSer
Copy link
Collaborator

aLekSer commented Apr 18, 2020

@akremsa Well, it seems that moving FEATURE_GATES up to a global level results in failing SDK conformance tests. What I would recommend is to change sdk.mk and set FEATURE_GATES there also,for some test it should be "". Or we should specify this variable for E2E tests and install separately.

Step #22 - "sdk-conformance": DOCKER_RUN_ARGS="--net host -e AGONES_SDK_GRPC_PORT=9002 -e AGONES_SDK_HTTP_PORT=9102 -e FEATURE_GATES="PlayerTracking=true&ContainerPortAllocation=true" " COMMAND=sdktest /usr/bin/make run-sdk-command & \
Step #22 - "sdk-conformance": docker run -p 9002:9002 -p 9102:9102 -e "FEATURE_GATES="PlayerTracking=true&ContainerPortAllocation=true"" -e "ADDRESS=" -e "TEST=ready,allocate,setlabel,setannotation,gameserver,health,shutdown,watch,reserve" -e "SDK_NAME=node" -e "TIMEOUT=30" -e "DELAY=3" \

Previously with Successful SDK test runs this parameter was an empty string:

DOCKER_RUN_ARGS="--net host -e AGONES_SDK_GRPC_PORT=9002 -e AGONES_SDK_HTTP_PORT=9102 -e FEATURE_GATES= " COMMAND=sdktest /usr/bin/make run-sdk-command & \
Step #22 - "sdk-conformance": docker run -p 9002:9002 -p 9102:9102 -e "FEATURE_GATES=" -e "ADDRESS=" -e "TEST=ready,allocate,setlabel,setannotation,gameserver,health,shutdown,watch,reserve" -e "SDK_NAME=node" -e "TIMEOUT=30" -e "DELAY=4" \
Step #22 - "sdk-conformance": --net=host gcr.io/agones-images/agones-sdk:1.6.0-75ba12c --grpc-port 9002 --http-port 9102
Step #22 - "sdk-conformance": DOCKER_RUN_ARGS="--net host -e AGONES_SDK_GRPC_PORT=9003 -e AGONES_SDK_HTTP_PORT=9103 -e FEATURE_GATES= " COMMAND=sdktest /usr/bin/make run-sdk-command 

@agones-bot
Copy link
Collaborator

Build Failed 😱

Build Id: 43495c1f-8940-4b43-af91-47b876a67ec6

To get permission to view the Cloud Build view, join the agones-discuss Google Group.

@agones-bot
Copy link
Collaborator

Build Succeeded 👏

Build Id: 0ec5d536-1c65-490b-bdf3-7f0d73217148

The following development artifacts have been built, and will exist for the next 30 days:

A preview of the website (the last 30 builds are retained):

To install this version:

  • git fetch https://github.com/GoogleCloudPlatform/agones.git pull/1445/head:pr_1445 && git checkout pr_1445
  • helm install ./install/helm/agones --namespace agones-system --name agones --set agones.image.tag=1.6.0-db126ad

@akremsa
Copy link
Contributor Author

akremsa commented Apr 20, 2020

@akremsa Well, it seems that moving FEATURE_GATES up to a global level results in failing SDK conformance tests. What I would recommend is to change sdk.mk and set FEATURE_GATES there also,for some test it should be "". Or we should specify this variable for E2E tests and install separately.

Step #22 - "sdk-conformance": DOCKER_RUN_ARGS="--net host -e AGONES_SDK_GRPC_PORT=9002 -e AGONES_SDK_HTTP_PORT=9102 -e FEATURE_GATES="PlayerTracking=true&ContainerPortAllocation=true" " COMMAND=sdktest /usr/bin/make run-sdk-command & \
Step #22 - "sdk-conformance": docker run -p 9002:9002 -p 9102:9102 -e "FEATURE_GATES="PlayerTracking=true&ContainerPortAllocation=true"" -e "ADDRESS=" -e "TEST=ready,allocate,setlabel,setannotation,gameserver,health,shutdown,watch,reserve" -e "SDK_NAME=node" -e "TIMEOUT=30" -e "DELAY=3" \

Previously with Successful SDK test runs this parameter was an empty string:

DOCKER_RUN_ARGS="--net host -e AGONES_SDK_GRPC_PORT=9002 -e AGONES_SDK_HTTP_PORT=9102 -e FEATURE_GATES= " COMMAND=sdktest /usr/bin/make run-sdk-command & \
Step #22 - "sdk-conformance": docker run -p 9002:9002 -p 9102:9102 -e "FEATURE_GATES=" -e "ADDRESS=" -e "TEST=ready,allocate,setlabel,setannotation,gameserver,health,shutdown,watch,reserve" -e "SDK_NAME=node" -e "TIMEOUT=30" -e "DELAY=4" \
Step #22 - "sdk-conformance": --net=host gcr.io/agones-images/agones-sdk:1.6.0-75ba12c --grpc-port 9002 --http-port 9102
Step #22 - "sdk-conformance": DOCKER_RUN_ARGS="--net host -e AGONES_SDK_GRPC_PORT=9003 -e AGONES_SDK_HTTP_PORT=9103 -e FEATURE_GATES= " COMMAND=sdktest /usr/bin/make run-sdk-command 

Fixed

build/includes/sdk.mk Outdated Show resolved Hide resolved
@@ -25,7 +25,8 @@ import (
)

const (
featureGateFlag = "feature-gates"
// FeatureGateFlag is a name of a command line flag, which turns on specific tests for FeatureGates
FeatureGateFlag = "feature-gates"
Copy link
Member

Choose a reason for hiding this comment

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

Nice! 👍

build/Makefile Outdated Show resolved Hide resolved
@agones-bot
Copy link
Collaborator

Build Succeeded 👏

Build Id: b745285d-8864-4e7f-bff1-5ffecd9d9f92

The following development artifacts have been built, and will exist for the next 30 days:

A preview of the website (the last 30 builds are retained):

To install this version:

  • git fetch https://github.com/GoogleCloudPlatform/agones.git pull/1445/head:pr_1445 && git checkout pr_1445
  • helm install ./install/helm/agones --namespace agones-system --name agones --set agones.image.tag=1.6.0-0bd2e7a

Copy link
Collaborator

@aLekSer aLekSer left a comment

Choose a reason for hiding this comment

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

Thanks for an update. Now running E2E tests make test-e2e FEATURE_FLAGS="" is possible on the cluster with stable features only and others disabled.

@agones-bot
Copy link
Collaborator

Build Succeeded 👏

Build Id: 45e8c9e4-bbc1-4fd4-88b0-8f96df5aa6b2

The following development artifacts have been built, and will exist for the next 30 days:

A preview of the website (the last 30 builds are retained):

To install this version:

  • git fetch https://github.com/GoogleCloudPlatform/agones.git pull/1445/head:pr_1445 && git checkout pr_1445
  • helm install ./install/helm/agones --namespace agones-system --name agones --set agones.image.tag=1.6.0-5a0c9d3

@akremsa akremsa requested a review from markmandel April 21, 2020 07:15
Copy link
Member

@markmandel markmandel left a comment

Choose a reason for hiding this comment

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

Let's do this!

@google-oss-robot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: akremsa, aLekSer, markmandel

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@google-oss-robot
Copy link

New changes are detected. LGTM label has been removed.

@markmandel markmandel added area/tests Unit tests, e2e tests, anything to make sure things don't break kind/feature New features for Agones area/build-tools Development tooling. I.e. pretty much everything in the `build` directory. labels Apr 21, 2020
@markmandel markmandel added this to the 1.6.0 milestone Apr 21, 2020
@agones-bot
Copy link
Collaborator

Build Succeeded 👏

Build Id: e179d369-bdcc-43e9-a9e3-c5393a21ae70

The following development artifacts have been built, and will exist for the next 30 days:

A preview of the website (the last 30 builds are retained):

To install this version:

  • git fetch https://github.com/GoogleCloudPlatform/agones.git pull/1445/head:pr_1445 && git checkout pr_1445
  • helm install ./install/helm/agones --namespace agones-system --name agones --set agones.image.tag=1.6.0-4c3974a

@markmandel markmandel merged commit eccc9d1 into googleforgames:master Apr 21, 2020
ilkercelikyilmaz pushed a commit to ilkercelikyilmaz/agones that referenced this pull request Oct 23, 2020
* Pass FEATURE_GATES flag to e2e tests

Co-authored-by: Alexander Apalikov <alexander.apalikov@globant.com>
Co-authored-by: Mark Mandel <markmandel@google.com>
ilkercelikyilmaz pushed a commit to ilkercelikyilmaz/agones that referenced this pull request Oct 23, 2020
* Pass FEATURE_GATES flag to e2e tests

Co-authored-by: Alexander Apalikov <alexander.apalikov@globant.com>
Co-authored-by: Mark Mandel <markmandel@google.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved area/build-tools Development tooling. I.e. pretty much everything in the `build` directory. area/tests Unit tests, e2e tests, anything to make sure things don't break kind/feature New features for Agones size/L
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants