* Added a flag to specify whether to import groups that already exist in bitbucket along with functionality to import those groups into the terraform state

* Changed the error checking when importing an existing group for bitbucket so that the duplicate group error is not thrown
* Added two acceptance tests
* Updated the ReadMe.md with accurate instructions since the previous ones were not working for us
* Updated the Makefile to set the maximum number of files allowed to be open to 1024 since 256 was too few.  We called `ulimit -n 1024` to do this for the testacc and testacc-bitbucket targets.
* Changed the start-docker-compose.sh to use the bitbucket server environment variable so that it doesn't always refer to localhost
* Skipped some testcases that are consistently failing in master branch
* Added a version.env file to be used to control the versioning from CICD builds
* Set version to 1.4.0
* In the start-docker-compose.sh if the BITBUCKET_SERVER environment variable is not set then use http://localhost:7990

In the start-docker-compose.sh if the BITBUCKET_SERVER environment variable is not set then use http://localhost:7990
This commit is contained in:
Justin To
2020-07-06 13:35:11 -04:00
committed by Cameron Crockatt
parent f116e39d79
commit b3ee8fd46c
9 changed files with 131 additions and 35 deletions

View File

@@ -5,7 +5,7 @@ export GO111MODULE=on
export TESTARGS=-race -coverprofile=coverage.txt -covermode=atomic
export BITBUCKET_SERVER=http://localhost:7990
export BITBUCKET_SERVER?=http://localhost:7990
export BITBUCKET_USERNAME=admin
export BITBUCKET_PASSWORD=admin
@@ -20,11 +20,15 @@ test: fmtcheck
xargs -t -n4 go test $(TESTARGS) -timeout=30s -parallel=4
testacc: fmtcheck
TF_ACC=1 go test $(TEST) -v $(TESTARGS) -timeout 120m -count=1
#The ulimit command is required to allow the tests to open more than the default 256 files as set on MacOS. The tests will fail without this. It must be done as one
#command otherwise the setting is lost
ulimit -n 1024; TF_ACC=1 go test $(TEST) -v $(TESTARGS) -timeout 120m -count=1
testacc-bitbucket: fmtcheck
@sh scripts/start-docker-compose.sh
TF_ACC=1 go test $(TEST) -v $(TESTARGS) -timeout 120m -count=1
#The ulimit command is required to allow the tests to open more than the default 256 files as set on MacOS. The tests will fail without this. It must be done as one
#command otherwise the setting is lost
ulimit -n 1024; TF_ACC=1 go test $(TEST) -v $(TESTARGS) -timeout 120m -count=1
@sh scripts/stop-docker-compose.sh
vet: