Refactor parameter serialization into TaskParameterSerializer

pull/310/head
Frostebite 2021-12-24 00:11:19 +00:00
parent cc0c007a6a
commit bedaf1f580
5 changed files with 361 additions and 2 deletions

View File

@ -0,0 +1,90 @@
androidKeystoreBase64=
androidKeystorePass=
ANDROID_VERSION_CODE=1
kubeConfig=
customImage=false
HOSTNAME=ip-10-0-0-253.eu-west-2.compute.internal
testCustomSecret=VALUEXXX
androidKeyaliasPass=
BUILDID=0-windows64-ccif
SHLVL=1
branch=remote-builder/unified-providers
githubRepo=game-ci/unity-builder
HOME=/root
cloudRunnerCpu=1.0
versioningStrategy=None
platform=StandaloneWindows64
version=2019.2.11f1
githubEnabled=false
ANDROID_KEYSTORE_NAME=
buildPathFull=/data/0-windows64-ccif
region=eu-west-2
AWS_EXECUTION_ENV=AWS_ECS_FARGATE
specifiedVersion=
BUILD_FILE=StandaloneWindows64.exe
runNumber=0
chownFilesTo=
BUILD_NAME=StandaloneWindows64
ANDROID_KEYALIAS_NAME=
buildMethod=
VERSION=none
logToFile=true
AWS_DEFAULT_REGION=eu-west-2
sshAgent=
androidVersionCode=false
runnerTempPath=undefined
BUILD_METHOD=
ECS_CONTAINER_METADATA_URI_V4=http://169.254.170.2/v4/47a8f1e95ae8450ea19ee1f52781a0b1-2314347076
androidKeystoreName=
kubeVolumeSize=5Gi
steamPathFull=/data/0-windows64-ccif/steam
CUSTOM_PARAMETERS=
customParameters=
ECS_CONTAINER_METADATA_URI=http://169.254.170.2/v3/47a8f1e95ae8450ea19ee1f52781a0b1-2314347076
repoPathFull=/data/0-windows64-ccif/repo
buildParameters={"version":"2019.2.11f1","customImage":false,"platform":"StandaloneWindows64","projectPath":"test-project","buildName":"StandaloneWindows64","buildPath":"build/StandaloneWindows64","buildFile":"StandaloneWindows64.exe","buildMethod":"","buildVersion":"none","androidVersionCode":1,"androidKeystoreName":"","androidKeystoreBase64":"","androidKeystorePass":"","androidKeyaliasName":"","androidKeyaliasPass":"","customParameters":"","sshAgent":"","chownFilesTo":"","cloudRunnerCluster":"","awsBaseStackName":"game-ci-3-test","kubeConfig":"","githubToken":"","cloudRunnerMemory":"750M","cloudRunnerCpu":"1.0","kubeVolumeSize":"5Gi","kubeVolume":"","postBuildSteps":"","preBuildSteps":"","customBuildSteps":"\n - name: 'step 1'\n image: 'alpine'\n commands: ['printenv']\n secrets:\n - name: 'testCustomSecret'\n value: 'VALUEXXX'\n ","runNumber":"0","branch":"remote-builder/unified-providers","githubRepo":"game-ci/unity-builder","logToFile":true}
cloudRunnerCluster=
PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
androidAppBundle=false
libraryFolderFull=/data/0-windows64-ccif/repo/test-project/Library
preBuildSteps=
androidKeyaliasName=
ContainerMemory=750M
buildFile=StandaloneWindows64.exe
projectPath=test-project
unityVersion=auto
BUILD_TARGET=StandaloneWindows64
buildName=StandaloneWindows64
targetPlatform=StandaloneWindows64
ALLOW_EMPTY_PASSWORD=yes
BUILD_PATH=build/StandaloneWindows64
PROJECT_PATH=test-project
AWS_REGION=eu-west-2
GITHUB_WORKSPACE=/github/workspace
awsBaseStackName=game-ci-3-test
length=0
builderPathFull=/data/0-windows64-ccif/builder
buildVersion=none
cliOptions=[object Object]
name=Input
cloudRunnerMemory=750M
postBuildSteps=
PWD=/data
buildsPath=build
allowDirtyBuild=false
githubToken=
UNITY_VERSION=2019.2.11f1
projectPathFull=/data/0-windows64-ccif/repo/test-project
buildPath=build/StandaloneWindows64
prototype=[object Object]
customBuildSteps=
- name: 'step 1'
image: 'alpine'
commands: ['printenv']
secrets:
- name: 'testCustomSecret'
value: 'VALUEXXX'
kubeVolume=
ContainerCpu=1.0
remoteBuilderIntegrationTests=true

View File

@ -0,0 +1,90 @@
androidKeystoreBase64=
androidKeystorePass=
ANDROID_VERSION_CODE=1
kubeConfig=
testCustomSecret=VALUEXXX
customImage=false
HOSTNAME=ip-10-0-1-96.eu-west-2.compute.internal
androidKeyaliasPass=
BUILDID=0-windows64-dcfb
SHLVL=1
githubRepo=game-ci/unity-builder
branch=remote-builder/unified-providers
HOME=/root
cloudRunnerCpu=1.0
versioningStrategy=None
platform=StandaloneWindows64
githubEnabled=false
ANDROID_KEYSTORE_NAME=
buildPathFull=/data/0-windows64-dcfb
version=2019.2.11f1
AWS_EXECUTION_ENV=AWS_ECS_FARGATE
region=eu-west-2
specifiedVersion=
BUILD_FILE=StandaloneWindows64.exe
chownFilesTo=
runNumber=0
ANDROID_KEYALIAS_NAME=
BUILD_NAME=StandaloneWindows64
buildMethod=
VERSION=none
AWS_DEFAULT_REGION=eu-west-2
logToFile=true
runnerTempPath=undefined
androidVersionCode=false
sshAgent=
ECS_CONTAINER_METADATA_URI_V4=http://169.254.170.2/v4/78002cef51e844cf8231cfa81d773040-1441607460
BUILD_METHOD=
androidKeystoreName=
customParameters=
ECS_CONTAINER_METADATA_URI=http://169.254.170.2/v3/78002cef51e844cf8231cfa81d773040-1441607460
kubeVolumeSize=5Gi
steamPathFull=/data/0-windows64-dcfb/steam
CUSTOM_PARAMETERS=
buildParameters={"version":"2019.2.11f1","customImage":false,"platform":"StandaloneWindows64","projectPath":"test-project","buildName":"StandaloneWindows64","buildPath":"build/StandaloneWindows64","buildFile":"StandaloneWindows64.exe","buildMethod":"","buildVersion":"none","androidVersionCode":1,"androidKeystoreName":"","androidKeystoreBase64":"","androidKeystorePass":"","androidKeyaliasName":"","androidKeyaliasPass":"","customParameters":"","sshAgent":"","chownFilesTo":"","cloudRunnerCluster":"","awsBaseStackName":"game-ci-3-test","kubeConfig":"","githubToken":"","cloudRunnerMemory":"750M","cloudRunnerCpu":"1.0","kubeVolumeSize":"5Gi","kubeVolume":"","postBuildSteps":"","preBuildSteps":"","customBuildSteps":"\n - name: 'step 1'\n image: 'alpine'\n commands: ['printenv']\n secrets:\n - name: 'testCustomSecret'\n value: 'VALUEXXX'\n ","runNumber":"0","branch":"remote-builder/unified-providers","githubRepo":"game-ci/unity-builder","logToFile":true}
cloudRunnerCluster=
repoPathFull=/data/0-windows64-dcfb/repo
PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
libraryFolderFull=/data/0-windows64-dcfb/repo/test-project/Library
androidAppBundle=false
androidKeyaliasName=
preBuildSteps=
buildFile=StandaloneWindows64.exe
projectPath=test-project
ContainerMemory=750M
buildName=StandaloneWindows64
BUILD_TARGET=StandaloneWindows64
unityVersion=auto
targetPlatform=StandaloneWindows64
BUILD_PATH=build/StandaloneWindows64
ALLOW_EMPTY_PASSWORD=yes
PROJECT_PATH=test-project
AWS_REGION=eu-west-2
awsBaseStackName=game-ci-3-test
GITHUB_WORKSPACE=/github/workspace
builderPathFull=/data/0-windows64-dcfb/builder
buildVersion=none
length=0
cliOptions=[object Object]
name=Input
cloudRunnerMemory=750M
postBuildSteps=
PWD=/data
allowDirtyBuild=false
buildsPath=build
githubToken=
UNITY_VERSION=2019.2.11f1
projectPathFull=/data/0-windows64-dcfb/repo/test-project
buildPath=build/StandaloneWindows64
customBuildSteps=
- name: 'step 1'
image: 'alpine'
commands: ['printenv']
secrets:
- name: 'testCustomSecret'
value: 'VALUEXXX'
prototype=[object Object]
ContainerCpu=1.0
kubeVolume=
remoteBuilderIntegrationTests=true

View File

@ -0,0 +1,90 @@
androidKeystoreBase64=
androidKeystorePass=
ANDROID_VERSION_CODE=1
kubeConfig=
testCustomSecret=VALUEXXX
HOSTNAME=ip-10-0-0-211.eu-west-2.compute.internal
customImage=false
androidKeyaliasPass=
BUILDID=0-windows64-k4ca
SHLVL=1
githubRepo=game-ci/unity-builder
branch=remote-builder/unified-providers
HOME=/root
cloudRunnerCpu=1.0
versioningStrategy=None
platform=StandaloneWindows64
version=2019.2.11f1
githubEnabled=false
ANDROID_KEYSTORE_NAME=
buildPathFull=/data/0-windows64-k4ca
region=eu-west-2
AWS_EXECUTION_ENV=AWS_ECS_FARGATE
specifiedVersion=
chownFilesTo=
BUILD_FILE=StandaloneWindows64.exe
runNumber=0
ANDROID_KEYALIAS_NAME=
buildMethod=
BUILD_NAME=StandaloneWindows64
VERSION=none
AWS_DEFAULT_REGION=eu-west-2
logToFile=true
sshAgent=
runnerTempPath=undefined
androidVersionCode=false
BUILD_METHOD=
androidKeystoreName=
ECS_CONTAINER_METADATA_URI_V4=http://169.254.170.2/v4/84ecec4a202b47cca637505e835d3b3e-2172599882
steamPathFull=/data/0-windows64-k4ca/steam
CUSTOM_PARAMETERS=
kubeVolumeSize=5Gi
customParameters=
ECS_CONTAINER_METADATA_URI=http://169.254.170.2/v3/84ecec4a202b47cca637505e835d3b3e-2172599882
repoPathFull=/data/0-windows64-k4ca/repo
buildParameters={"version":"2019.2.11f1","customImage":false,"platform":"StandaloneWindows64","projectPath":"test-project","buildName":"StandaloneWindows64","buildPath":"build/StandaloneWindows64","buildFile":"StandaloneWindows64.exe","buildMethod":"","buildVersion":"none","androidVersionCode":1,"androidKeystoreName":"","androidKeystoreBase64":"","androidKeystorePass":"","androidKeyaliasName":"","androidKeyaliasPass":"","customParameters":"","sshAgent":"","chownFilesTo":"","cloudRunnerCluster":"","awsBaseStackName":"game-ci-3-test","kubeConfig":"","githubToken":"","cloudRunnerMemory":"750M","cloudRunnerCpu":"1.0","kubeVolumeSize":"5Gi","kubeVolume":"","postBuildSteps":"","preBuildSteps":"","customBuildSteps":"\n - name: 'step 1'\n image: 'alpine'\n commands: ['printenv']\n secrets:\n - name: 'testCustomSecret'\n value: 'VALUEXXX'\n ","runNumber":"0","branch":"remote-builder/unified-providers","githubRepo":"game-ci/unity-builder","logToFile":true}
cloudRunnerCluster=
PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
androidAppBundle=false
libraryFolderFull=/data/0-windows64-k4ca/repo/test-project/Library
androidKeyaliasName=
preBuildSteps=
buildFile=StandaloneWindows64.exe
projectPath=test-project
ContainerMemory=750M
unityVersion=auto
BUILD_TARGET=StandaloneWindows64
buildName=StandaloneWindows64
targetPlatform=StandaloneWindows64
ALLOW_EMPTY_PASSWORD=yes
BUILD_PATH=build/StandaloneWindows64
PROJECT_PATH=test-project
AWS_REGION=eu-west-2
GITHUB_WORKSPACE=/github/workspace
awsBaseStackName=game-ci-3-test
length=0
builderPathFull=/data/0-windows64-k4ca/builder
buildVersion=none
cliOptions=[object Object]
postBuildSteps=
name=Input
cloudRunnerMemory=750M
PWD=/data
allowDirtyBuild=false
buildsPath=build
githubToken=
UNITY_VERSION=2019.2.11f1
projectPathFull=/data/0-windows64-k4ca/repo/test-project
buildPath=build/StandaloneWindows64
customBuildSteps=
- name: 'step 1'
image: 'alpine'
commands: ['printenv']
secrets:
- name: 'testCustomSecret'
value: 'VALUEXXX'
kubeVolume=
prototype=[object Object]
ContainerCpu=1.0
remoteBuilderIntegrationTests=true

View File

@ -0,0 +1,90 @@
androidKeystorePass=
androidKeystoreBase64=
ANDROID_VERSION_CODE=1
kubeConfig=
HOSTNAME=ip-10-0-0-145.eu-west-2.compute.internal
testCustomSecret=VALUEXXX
customImage=false
BUILDID=0-windows64-ngbx
androidKeyaliasPass=
SHLVL=1
branch=remote-builder/unified-providers
githubRepo=game-ci/unity-builder
HOME=/root
cloudRunnerCpu=1.0
versioningStrategy=None
platform=StandaloneWindows64
version=2019.2.11f1
githubEnabled=false
ANDROID_KEYSTORE_NAME=
buildPathFull=/data/0-windows64-ngbx
AWS_EXECUTION_ENV=AWS_ECS_FARGATE
region=eu-west-2
specifiedVersion=
runNumber=0
BUILD_FILE=StandaloneWindows64.exe
chownFilesTo=
BUILD_NAME=StandaloneWindows64
buildMethod=
ANDROID_KEYALIAS_NAME=
VERSION=none
logToFile=true
AWS_DEFAULT_REGION=eu-west-2
androidVersionCode=false
runnerTempPath=undefined
sshAgent=
ECS_CONTAINER_METADATA_URI_V4=http://169.254.170.2/v4/5d64168aa77f47fbbc47c30249ec45ab-3319054972
androidKeystoreName=
BUILD_METHOD=
CUSTOM_PARAMETERS=
kubeVolumeSize=5Gi
ECS_CONTAINER_METADATA_URI=http://169.254.170.2/v3/5d64168aa77f47fbbc47c30249ec45ab-3319054972
customParameters=
steamPathFull=/data/0-windows64-ngbx/steam
repoPathFull=/data/0-windows64-ngbx/repo
buildParameters={"version":"2019.2.11f1","customImage":false,"platform":"StandaloneWindows64","projectPath":"test-project","buildName":"StandaloneWindows64","buildPath":"build/StandaloneWindows64","buildFile":"StandaloneWindows64.exe","buildMethod":"","buildVersion":"none","androidVersionCode":1,"androidKeystoreName":"","androidKeystoreBase64":"","androidKeystorePass":"","androidKeyaliasName":"","androidKeyaliasPass":"","customParameters":"","sshAgent":"","chownFilesTo":"","cloudRunnerCluster":"","awsBaseStackName":"game-ci-3-test","kubeConfig":"","githubToken":"","cloudRunnerMemory":"750M","cloudRunnerCpu":"1.0","kubeVolumeSize":"5Gi","kubeVolume":"","postBuildSteps":"","preBuildSteps":"","customBuildSteps":"\n - name: 'step 1'\n image: 'alpine'\n commands: ['printenv']\n secrets:\n - name: 'testCustomSecret'\n value: 'VALUEXXX'\n ","runNumber":"0","branch":"remote-builder/unified-providers","githubRepo":"game-ci/unity-builder","logToFile":true}
cloudRunnerCluster=
PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
androidAppBundle=false
libraryFolderFull=/data/0-windows64-ngbx/repo/test-project/Library
preBuildSteps=
androidKeyaliasName=
projectPath=test-project
buildFile=StandaloneWindows64.exe
ContainerMemory=750M
buildName=StandaloneWindows64
BUILD_TARGET=StandaloneWindows64
unityVersion=auto
targetPlatform=StandaloneWindows64
BUILD_PATH=build/StandaloneWindows64
ALLOW_EMPTY_PASSWORD=yes
PROJECT_PATH=test-project
AWS_REGION=eu-west-2
awsBaseStackName=game-ci-3-test
GITHUB_WORKSPACE=/github/workspace
buildVersion=none
builderPathFull=/data/0-windows64-ngbx/builder
length=0
cliOptions=[object Object]
cloudRunnerMemory=750M
postBuildSteps=
name=Input
PWD=/data
allowDirtyBuild=false
buildsPath=build
UNITY_VERSION=2019.2.11f1
githubToken=
buildPath=build/StandaloneWindows64
projectPathFull=/data/0-windows64-ngbx/repo/test-project
customBuildSteps=
- name: 'step 1'
image: 'alpine'
commands: ['printenv']
secrets:
- name: 'testCustomSecret'
value: 'VALUEXXX'
kubeVolume=
prototype=[object Object]
ContainerCpu=1.0
remoteBuilderIntegrationTests=true

View File

@ -32,8 +32,7 @@ describe('Cloud Runner', () => {
const inputKeys = Object.getOwnPropertyNames(Input);
for (const element of inputKeys) {
if (Input[element] !== undefined && typeof Input[element] != 'function') {
expect(file).toContain(`${element}`);
expect(file).toContain(`${Input[element]}`);
expect(file.replace(/\s+/g, '')).toContain(`${element}=${Input[element].toString().replace(/\s+/g, '')}`);
}
}
}