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

tests.sh does not run cleanly on Mac OS X #12

Open
dansoton opened this issue Mar 17, 2015 · 1 comment
Open

tests.sh does not run cleanly on Mac OS X #12

dansoton opened this issue Mar 17, 2015 · 1 comment

Comments

@dansoton
Copy link

I'm not sure how tests.sh runs on other Mac OS X machines, but when I run it I get the following errors, none of them look to me like they should work on other Mac OS X systems.

Recreate:

git clone git@github.com:lehmannro/assert.sh.git assert.sh-framework
cd assert.sh-framework
./tests.sh

Output:

all 9 demo tests passed in 0.000s.
test #15 "_clean; skip_if 'cat /etc/passwd | grep $(echo $USER)';
assert_raises false; assert_end;" failed:
    expected "all 0 tests passed."
    got "test #1 "false" failed:\n  program terminated with code 1 instead of 0\n1 of 1 tests failed."
1 of 15 output tests failed in 0.000s.
test #11 "shopt -o errexit" failed:
    program terminated with code 1 instead of 0
1 of 15 interaction tests failed in 1.000s.
test #10 "echo -n %s | wc -c" failed:
    expected "2"
    got "       2"
1 of 11 regression tests failed in 0.000s.
  • Test 15 is because the current user on Mac OS X is unlikely to be in /etc/passwd because regular users aren't stored in there but in its Open Directory service.
  • Test 11 - I have no idea.
  • Test 10 is I guess because Mac OS's wc is the BSD version and not the gnu version, and the output seems to differ with the BSD version.

(I tried both master branch and v1.1 tag).

@dansoton
Copy link
Author

I fixed this in a separate commit in Pull Request #13 so if that PR is accepted, this issue can be closed, otherwise a separate PR can be made to extract the commit out.

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

No branches or pull requests

1 participant