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

aws_dms_endpoint TestAccAwsDmsEndpointMongoDb acceptance test is failing #7492

Closed
fewstera opened this issue Feb 9, 2019 · 3 comments
Closed
Labels
tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure.

Comments

@fewstera
Copy link
Contributor

fewstera commented Feb 9, 2019

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or "me too" comments, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

Affected Resource(s)

  • aws_dms_endpoint

Test output

make testacc TESTARGS='-run=TestAccAwsDmsEndpointMongo'
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./... -v -parallel 20 -run=TestAccAwsDmsEndpointMongo -timeout 120m
?       github.com/terraform-providers/terraform-provider-aws   [no test files]
=== RUN   TestAccAwsDmsEndpointMongoDb
=== PAUSE TestAccAwsDmsEndpointMongoDb
=== CONT  TestAccAwsDmsEndpointMongoDb
--- FAIL: TestAccAwsDmsEndpointMongoDb (20.36s)
    testing.go:538: Step 0 error: After applying this step, the plan was not empty:

        DIFF:

        UPDATE: aws_dms_endpoint.dms_endpoint
          mongodb_settings.0.auth_mechanism: "default" => "DEFAULT"
          mongodb_settings.0.auth_type:      "password" => "PASSWORD"
          mongodb_settings.0.nesting_level:  "none" => "NONE"

        STATE:

        aws_dms_endpoint.dms_endpoint:
          ID = tf-test-dms-endpoint-nccyu106-mongodb
          provider = provider.aws
          certificate_arn =
          database_name = tftest
          endpoint_arn = arn:aws:dms:us-west-2:1111111111111111:endpoint:POWQBB4ALBFF5XNHDE4QEQY6UM
          endpoint_id = tf-test-dms-endpoint-nccyu106-mongodb
          endpoint_type = source
          engine_name = mongodb
          kms_key_arn = arn:aws:kms:us-west-2:1111111111111111:key/fffffffffffff-ef5f-4263-a44c-6ebb0e4ef980
          mongodb_settings.# = 1
          mongodb_settings.0.auth_mechanism = default
          mongodb_settings.0.auth_source = admin
          mongodb_settings.0.auth_type = password
          mongodb_settings.0.docs_to_investigate = 1000
          mongodb_settings.0.extract_doc_id = false
          mongodb_settings.0.nesting_level = none
          password = tftest
          port = 27017
          server_name = tftest
          ssl_mode = none
          tags.% = 3
          tags.Name = tf-test-dms-endpoint-nccyu106-mongodb
          tags.Remove = to-remove
          tags.Update = to-update
          username = tftest

          Dependencies:
            data.aws_kms_alias.dms
        data.aws_kms_alias.dms:
          ID = 2019-02-09 15:34:00.540457 +0000 UTC
          provider = provider.aws
          arn = arn:aws:kms:us-west-2:1111111111111111:alias/aws/dms
          name = alias/aws/dms
          target_key_arn = arn:aws:kms:us-west-2:1111111111111111:key/fffffffffffff-ef5f-4263-a44c-6ebb0e4ef980
          target_key_id =fffffffffffff-ef5f-4263-a44c-6ebb0e4ef980
FAIL
FAIL    github.com/terraform-providers/terraform-provider-aws/aws       20.402s
make: *** [GNUmakefile:20: testacc] Error 1

Info

I've just tried to run the acceptance tests with make testacc TESTARGS='-run=TestAccAwsDmsEndpointand it appears the TestAccAwsDmsEndpointMongodb test is failing.

The issue seems to be that it sets mongodb_settings.(auth_type | auth_mechanism | nesting_level) using uppercase strings (like the docs suggest https://docs.aws.amazon.com/sdk-for-go/api/service/databasemigrationservice/#MongoDbSettings), but AWS returns the response with them in lower case.

Also in the update step of the test, it sets the auth_mechanism to SCRAM_SHA_1, but AWS returns scram-sha-1 - lowercased and hyphenated instead of underscored.

I'm not sure how's the best way to fix this issue.

@nywilken nywilken added tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. service/databasemigrationservice labels Feb 10, 2019
@ewbankkit
Copy link
Contributor

I've opened aws/aws-sdk-go#2522 to track the scram_sha_1 vs. scram-sha-1 issue.

@aeschright aeschright added the needs-triage Waiting for first response or review from a maintainer. label Jun 24, 2019
@aeschright
Copy link
Contributor

This test appears to be passing consistently in our CI now so I'm going to close the issue. Thanks!

@aeschright aeschright removed the needs-triage Waiting for first response or review from a maintainer. label Nov 22, 2019
@ghost
Copy link

ghost commented Mar 29, 2020

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thanks!

@ghost ghost locked and limited conversation to collaborators Mar 29, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure.
Projects
None yet
Development

No branches or pull requests

4 participants