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

Clitest update #1872

merged 1 commit into from Jun 3, 2016


Copy link

commented Jun 2, 2016

There was a bad if/elif statement and the elif os.path ... would never get hit. So I swapped the order of those two statements and added testing for the prepare_exec_for_file function.


This comment has been minimized.

Copy link

commented Jun 2, 2016

second commit should be amended into the first one

also, the first line of a commit should be no longer than 51 chars (right not even github truncates it) - see for some useful guidelines

@jphilipsen05 jphilipsen05 force-pushed the jphilipsen05:clitest_update branch 2 times, most recently from 2e0d78a to 0355d93 Jun 2, 2016

fixed unmatched elif
Also update relevant test

@jphilipsen05 jphilipsen05 force-pushed the jphilipsen05:clitest_update branch from 0355d93 to 9d7c370 Jun 2, 2016


This comment has been minimized.

Copy link

commented Jun 3, 2016

@ThiefMaster We can squash ourselves so commit styling is no longer that relevant.

@jphilipsen05 Can you verify (on your machine) that the tests fail without the bugfix?

@untitaker untitaker self-assigned this Jun 3, 2016


This comment has been minimized.

Copy link
Contributor Author

commented Jun 3, 2016

Yes, If I swap the if/elif statements back to the original I get this error in the tests. Showing that the first if statement for an is hitting the if statement that handles python files and does not reach the expected elif statement.

When I have my bug fix in place there are no errors.

Let me know if you have any other questions.

test_apps = None

    def test_prepare_exec_for_file(test_apps):
        assert prepare_exec_for_file('') == 'test'
>       assert prepare_exec_for_file('/usr/share/') == 'share'
E       assert '__init__' == 'share'
E         - __init__
E         + share

@untitaker untitaker merged commit fe5f714 into pallets:master Jun 3, 2016

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed

untitaker added a commit that referenced this pull request Jun 3, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
3 participants
You can’t perform that action at this time.