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

Added test cases for quoted strings. #173

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

jessealva
Copy link
Contributor

@jessealva jessealva commented Nov 30, 2017

These are some missing tests for apache/openwhisk#2462. Not all strings are reachable...some are in debug messages and there is no facility for enabling debugging in the cli in tests right now.

Also some of these are not reachable as there is no way for me to force a break of the code as the messages are embedded in an automated sdk install portion of the code.

I added as many tests as I could based on what was reachable via the testing framework.

@jessealva
Copy link
Contributor Author

jessealva commented Nov 30, 2017

@drcariel would you like to review this guy and see what you think?

Looks like this failed cause i have dependencies on apache/openwhisk#3045 changes that this obviously doesnt have yet...making a change over there

@jessealva jessealva force-pushed the fix-164-add-quote-tests branch from 92a8ff2 to 3b320e1 Compare January 8, 2018 16:17
Copy link
Member

@dubee dubee left a comment

Choose a reason for hiding this comment

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

Nice test coverage additions!

@@ -82,6 +84,76 @@ class WskSdkTests extends TestHelpers with WskTestHelpers {
}
}

it should "download docker sdk when blackbox.tar.gz exists, and docker name should be quoted in error." in {
Copy link
Member

Choose a reason for hiding this comment

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

Could use Seq to squash this test and "download ios sdk when OpenWhiskIOSStarterApp.zip exists, and ios name should be quoted in error. into one test.

}
}

it should "download ios sdk, check filename is quoted in error when create fails." in {
Copy link
Member

Choose a reason for hiding this comment

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

Can we expect the same directory permission issue with the Docker SDK?

$ mkdir wskinstall
$ chmod 555 wskinstall
$ cd wskinstall
$ wsk sdk install docker
error: The docker SDK installation failed: Error creating SDK file 'blackbox.tar.gz': open blackbox.tar.gz: permission denied

Could test both with Seq.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'll have to double check this one but last i checked i think there was no way to inject the bad permissions between the download and extraction.

@houshengbo
Copy link

@jessealva please take a look at the issue: #221 Travis build is not happy at this moment, due to async with openwhisk.

@rabbah
Copy link
Member

rabbah commented Jan 26, 2019

@dubee this needs a rebase --- is this something you can do? otherwise going to close this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants