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

CLI utilities tests fail on macOS #100

Open
da4089 opened this issue Jan 29, 2025 · 1 comment
Open

CLI utilities tests fail on macOS #100

da4089 opened this issue Jan 29, 2025 · 1 comment
Labels
bug Something isn't working

Comments

@da4089
Copy link

da4089 commented Jan 29, 2025

Quick Summary
The two CLI utilities test cases fail when running on macOS.

Context

  • vObject version: master
  • Python version: 3.9
  • Operating system and version: macOS "Big Sur" 11.7.10

Description

====================================================================================================== FAILURES =======================================================================================================
___________________________________________________________________________________________________ test_change_tz ____________________________________________________________________________________________________

    def test_change_tz():
        result = run_cli_tool(Cli.change_tz, ["--version"])
        assert result.returncode == 0

        result = run_cli_tool(Cli.change_tz, [])
>       assert result.returncode == 2
E       assert 0 == 2
E        +  where 0 = CompletedProcess(args=['change_tz'], returncode=0, stdout="error: too few arguments given\nUsage: change_tz [options] ics_file [timezone]\n\nchange_tz will convert the timezones in an ics file.\n\nOptions:\n  --version       show program's version number and exit\n  -h, --help      show this help message and exit\n  -u, --only-utc  Only change UTC events.\n  -l, --list      List available timezones\n\n", stderr='').returncode

tests/test_cli.py:19: AssertionError
____________________________________________________________________________________________________ test_ics_diff ____________________________________________________________________________________________________

    def test_ics_diff():
        result = run_cli_tool(Cli.ics_diff, ["--version"])
        assert result.returncode == 0

        result = run_cli_tool(Cli.ics_diff, [])
>       assert result.returncode == 2
E       assert 0 == 2
E        +  where 0 = CompletedProcess(args=['ics_diff'], returncode=0, stdout="error: too few arguments given\nUsage: ics_diff [options] ics_file1 ics_file2\n\nics_diff will print a comparison of two iCalendar files\n\nOptions:\n  --version             show program's version number and exit\n  -h, --help            show this help message and exit\n  -i, --ignore-dtstamp  ignore DTSTAMP lines [default: False]\n\n", stderr='').returncode

tests/test_cli.py:28: AssertionError
=============================================================================================== short test summary info ===============================================================================================
FAILED tests/test_cli.py::test_change_tz - assert 0 == 2
FAILED tests/test_cli.py::test_ics_diff - assert 0 == 2
============================================================================================ 2 failed, 56 passed in 17.11s ============================================================================================

To Reproduce

pytest -v tests

Further Notes
I haven't investigated this in sufficient detail yet; creating this issue so I don't forget.

@da4089 da4089 added the bug Something isn't working label Jan 29, 2025
@rsb-23
Copy link

rsb-23 commented Jan 29, 2025

I think we should add test_os.yml in workflow with base python and all 3 OS to avoid this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants