Skip to content

Commit

Permalink
Update line-endings for Windows
Browse files Browse the repository at this point in the history
  • Loading branch information
hoxbro committed May 22, 2024
1 parent 470aa0a commit ce1b59f
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions panel/tests/ui/widgets/test_input.py
Original file line number Diff line number Diff line change
Expand Up @@ -733,7 +733,9 @@ def test_filedropper_text_file(page):
page.set_input_files('input[type="file"]', file)

wait_until(lambda: len(widget.value) == 1, page)
assert widget.value == {file.name: file.read_text()}
assert widget.value == {

Check failure on line 736 in panel/tests/ui/widgets/test_input.py

View workflow job for this annotation

GitHub Actions / ui:test-ui:ubuntu-latest

test_filedropper_text_file assert {'test_input...."),\n }\n'} == {'test_input...."),\n }\n'} Differing items: {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...1.read_text().replace(r"\\r\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\r\\n", r"\\n"),\n }\n'} != {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...: file1.read_text().replace(r"\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\n", r"\\n"),\n }\n'} Full diff: { 'test_input.py': 'import datetime\n' '\n' 'from pathlib import Path\n' '\n' 'import numpy as np\n' 'import pytest\n' '\n' 'import panel as pn\n' '\n' 'pytest.importorskip("playwright")\n' '\n' 'from playwright.sync_api import Error, expect\n' '\n' 'from panel.tests.util import serve_component, wait_until\n' 'from panel.widgets import (\n' ' DatetimePicker, DatetimeRangePicker, TextAreaInput, ' 'TextInput,\n' ')\n' '\n' 'pytestmark = pytest.mark.ui\n' '\n' '\n' '@pytest.fixture\n' 'def weekdays_as_str():\n' " weekdays_str = '''\n" ' Sun\n' ' Mon\n' ' Tue\n' ' Wed\n' ' Thu\n' ' Fri\n' ' Sat\n' " '''\n" ' return weekdays_str\n' '\n' '\n' '@pytest.fixture\n' 'def months_as_str():\n' " months_str = '''\n" ' January\n' ' February\n' ' March\n' ' April\n' ' May\n' ' June\n' ' July\n' ' August\n' ' September\n' ' October\n' ' November\n' ' December\n' " '''\n" ' return months_str\n' '\n' '\n' '@pytest.fixture\n' 'def march_2021():\n' ' march_2021_days = [\n' ' 28, 1, 2, 3, 4, 5, 6, # 1st week\n' ' 7, 8, 9, 10, 11, 12, 13, # 2nd week\n' ' 14, 15, 16, 17, 18, 19, 20, # 3rd week\n' ' 21, 22, 23, 24, 25, 26, 27, # 4th week\n' ' 28, 29, 30, 31, 1, 2, 3, # 5th week\n' ' 4, 5, 6, 7, 8, 9, 10 # 6th week\n' ' ]\n' " march_2021_str = '\\n'.join([str(i) for i in " 'march_2021_days])\n' ' num_days = 42\n' ' num_prev_month_days = 1\n' ' num_next_month_days = 10\n' ' return march_2021_str, num_days, num_prev_month_days, ' 'num_next_month_days\n' '\n' '\n' '@pytest.fixture\n' 'def datetime_value_data():\n' ' year, month, day, ho

Check failure on line 736 in panel/tests/ui/widgets/test_input.py

View workflow job for this annotation

GitHub Actions / ui:test-ui:ubuntu-latest

test_filedropper_text_file assert {'test_input...."),\n }\n'} == {'test_input...."),\n }\n'} Differing items: {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...1.read_text().replace(r"\\r\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\r\\n", r"\\n"),\n }\n'} != {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...: file1.read_text().replace(r"\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\n", r"\\n"),\n }\n'} Full diff: { 'test_input.py': 'import datetime\n' '\n' 'from pathlib import Path\n' '\n' 'import numpy as np\n' 'import pytest\n' '\n' 'import panel as pn\n' '\n' 'pytest.importorskip("playwright")\n' '\n' 'from playwright.sync_api import Error, expect\n' '\n' 'from panel.tests.util import serve_component, wait_until\n' 'from panel.widgets import (\n' ' DatetimePicker, DatetimeRangePicker, TextAreaInput, ' 'TextInput,\n' ')\n' '\n' 'pytestmark = pytest.mark.ui\n' '\n' '\n' '@pytest.fixture\n' 'def weekdays_as_str():\n' " weekdays_str = '''\n" ' Sun\n' ' Mon\n' ' Tue\n' ' Wed\n' ' Thu\n' ' Fri\n' ' Sat\n' " '''\n" ' return weekdays_str\n' '\n' '\n' '@pytest.fixture\n' 'def months_as_str():\n' " months_str = '''\n" ' January\n' ' February\n' ' March\n' ' April\n' ' May\n' ' June\n' ' July\n' ' August\n' ' September\n' ' October\n' ' November\n' ' December\n' " '''\n" ' return months_str\n' '\n' '\n' '@pytest.fixture\n' 'def march_2021():\n' ' march_2021_days = [\n' ' 28, 1, 2, 3, 4, 5, 6, # 1st week\n' ' 7, 8, 9, 10, 11, 12, 13, # 2nd week\n' ' 14, 15, 16, 17, 18, 19, 20, # 3rd week\n' ' 21, 22, 23, 24, 25, 26, 27, # 4th week\n' ' 28, 29, 30, 31, 1, 2, 3, # 5th week\n' ' 4, 5, 6, 7, 8, 9, 10 # 6th week\n' ' ]\n' " march_2021_str = '\\n'.join([str(i) for i in " 'march_2021_days])\n' ' num_days = 42\n' ' num_prev_month_days = 1\n' ' num_next_month_days = 10\n' ' return march_2021_str, num_days, num_prev_month_days, ' 'num_next_month_days\n' '\n' '\n' '@pytest.fixture\n' 'def datetime_value_data():\n' ' year, month, day, ho

Check failure on line 736 in panel/tests/ui/widgets/test_input.py

View workflow job for this annotation

GitHub Actions / ui:test-ui:ubuntu-latest

test_filedropper_text_file assert {'test_input...."),\n }\n'} == {'test_input...."),\n }\n'} Differing items: {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...1.read_text().replace(r"\\r\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\r\\n", r"\\n"),\n }\n'} != {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...: file1.read_text().replace(r"\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\n", r"\\n"),\n }\n'} Full diff: { 'test_input.py': 'import datetime\n' '\n' 'from pathlib import Path\n' '\n' 'import numpy as np\n' 'import pytest\n' '\n' 'import panel as pn\n' '\n' 'pytest.importorskip("playwright")\n' '\n' 'from playwright.sync_api import Error, expect\n' '\n' 'from panel.tests.util import serve_component, wait_until\n' 'from panel.widgets import (\n' ' DatetimePicker, DatetimeRangePicker, TextAreaInput, ' 'TextInput,\n' ')\n' '\n' 'pytestmark = pytest.mark.ui\n' '\n' '\n' '@pytest.fixture\n' 'def weekdays_as_str():\n' " weekdays_str = '''\n" ' Sun\n' ' Mon\n' ' Tue\n' ' Wed\n' ' Thu\n' ' Fri\n' ' Sat\n' " '''\n" ' return weekdays_str\n' '\n' '\n' '@pytest.fixture\n' 'def months_as_str():\n' " months_str = '''\n" ' January\n' ' February\n' ' March\n' ' April\n' ' May\n' ' June\n' ' July\n' ' August\n' ' September\n' ' October\n' ' November\n' ' December\n' " '''\n" ' return months_str\n' '\n' '\n' '@pytest.fixture\n' 'def march_2021():\n' ' march_2021_days = [\n' ' 28, 1, 2, 3, 4, 5, 6, # 1st week\n' ' 7, 8, 9, 10, 11, 12, 13, # 2nd week\n' ' 14, 15, 16, 17, 18, 19, 20, # 3rd week\n' ' 21, 22, 23, 24, 25, 26, 27, # 4th week\n' ' 28, 29, 30, 31, 1, 2, 3, # 5th week\n' ' 4, 5, 6, 7, 8, 9, 10 # 6th week\n' ' ]\n' " march_2021_str = '\\n'.join([str(i) for i in " 'march_2021_days])\n' ' num_days = 42\n' ' num_prev_month_days = 1\n' ' num_next_month_days = 10\n' ' return march_2021_str, num_days, num_prev_month_days, ' 'num_next_month_days\n' '\n' '\n' '@pytest.fixture\n' 'def datetime_value_data():\n' ' year, month, day, ho

Check failure on line 736 in panel/tests/ui/widgets/test_input.py

View workflow job for this annotation

GitHub Actions / ui:test-ui:ubuntu-latest

test_filedropper_text_file assert {'test_input...."),\n }\n'} == {'test_input...."),\n }\n'} Differing items: {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...1.read_text().replace(r"\\r\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\r\\n", r"\\n"),\n }\n'} != {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...: file1.read_text().replace(r"\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\n", r"\\n"),\n }\n'} Full diff: { 'test_input.py': 'import datetime\n' '\n' 'from pathlib import Path\n' '\n' 'import numpy as np\n' 'import pytest\n' '\n' 'import panel as pn\n' '\n' 'pytest.importorskip("playwright")\n' '\n' 'from playwright.sync_api import Error, expect\n' '\n' 'from panel.tests.util import serve_component, wait_until\n' 'from panel.widgets import (\n' ' DatetimePicker, DatetimeRangePicker, TextAreaInput, ' 'TextInput,\n' ')\n' '\n' 'pytestmark = pytest.mark.ui\n' '\n' '\n' '@pytest.fixture\n' 'def weekdays_as_str():\n' " weekdays_str = '''\n" ' Sun\n' ' Mon\n' ' Tue\n' ' Wed\n' ' Thu\n' ' Fri\n' ' Sat\n' " '''\n" ' return weekdays_str\n' '\n' '\n' '@pytest.fixture\n' 'def months_as_str():\n' " months_str = '''\n" ' January\n' ' February\n' ' March\n' ' April\n' ' May\n' ' June\n' ' July\n' ' August\n' ' September\n' ' October\n' ' November\n' ' December\n' " '''\n" ' return months_str\n' '\n' '\n' '@pytest.fixture\n' 'def march_2021():\n' ' march_2021_days = [\n' ' 28, 1, 2, 3, 4, 5, 6, # 1st week\n' ' 7, 8, 9, 10, 11, 12, 13, # 2nd week\n' ' 14, 15, 16, 17, 18, 19, 20, # 3rd week\n' ' 21, 22, 23, 24, 25, 26, 27, # 4th week\n' ' 28, 29, 30, 31, 1, 2, 3, # 5th week\n' ' 4, 5, 6, 7, 8, 9, 10 # 6th week\n' ' ]\n' " march_2021_str = '\\n'.join([str(i) for i in " 'march_2021_days])\n' ' num_days = 42\n' ' num_prev_month_days = 1\n' ' num_next_month_days = 10\n' ' return march_2021_str, num_days, num_prev_month_days, ' 'num_next_month_days\n' '\n' '\n' '@pytest.fixture\n' 'def datetime_value_data():\n' ' year, month, day, ho

Check failure on line 736 in panel/tests/ui/widgets/test_input.py

View workflow job for this annotation

GitHub Actions / ui:test-ui:macos-latest

test_filedropper_text_file assert {'test_input...."),\n }\n'} == {'test_input...."),\n }\n'} Differing items: {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...1.read_text().replace(r"\\r\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\r\\n", r"\\n"),\n }\n'} != {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...: file1.read_text().replace(r"\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\n", r"\\n"),\n }\n'} Full diff: { 'test_input.py': 'import datetime\n' '\n' 'from pathlib import Path\n' '\n' 'import numpy as np\n' 'import pytest\n' '\n' 'import panel as pn\n' '\n' 'pytest.importorskip("playwright")\n' '\n' 'from playwright.sync_api import Error, expect\n' '\n' 'from panel.tests.util import serve_component, wait_until\n' 'from panel.widgets import (\n' ' DatetimePicker, DatetimeRangePicker, TextAreaInput, ' 'TextInput,\n' ')\n' '\n' 'pytestmark = pytest.mark.ui\n' '\n' '\n' '@pytest.fixture\n' 'def weekdays_as_str():\n' " weekdays_str = '''\n" ' Sun\n' ' Mon\n' ' Tue\n' ' Wed\n' ' Thu\n' ' Fri\n' ' Sat\n' " '''\n" ' return weekdays_str\n' '\n' '\n' '@pytest.fixture\n' 'def months_as_str():\n' " months_str = '''\n" ' January\n' ' February\n' ' March\n' ' April\n' ' May\n' ' June\n' ' July\n' ' August\n' ' September\n' ' October\n' ' November\n' ' December\n' " '''\n" ' return months_str\n' '\n' '\n' '@pytest.fixture\n' 'def march_2021():\n' ' march_2021_days = [\n' ' 28, 1, 2, 3, 4, 5, 6, # 1st week\n' ' 7, 8, 9, 10, 11, 12, 13, # 2nd week\n' ' 14, 15, 16, 17, 18, 19, 20, # 3rd week\n' ' 21, 22, 23, 24, 25, 26, 27, # 4th week\n' ' 28, 29, 30, 31, 1, 2, 3, # 5th week\n' ' 4, 5, 6, 7, 8, 9, 10 # 6th week\n' ' ]\n' " march_2021_str = '\\n'.join([str(i) for i in " 'march_2021_days])\n' ' num_days = 42\n' ' num_prev_month_days = 1\n' ' num_next_month_days = 10\n' ' return march_2021_str, num_days, num_prev_month_days, ' 'num_next_month_days\n' '\n' '\n' '@pytest.fixture\n' 'def datetime_value_data():\n' ' year, month, day, ho

Check failure on line 736 in panel/tests/ui/widgets/test_input.py

View workflow job for this annotation

GitHub Actions / ui:test-ui:macos-latest

test_filedropper_text_file assert {'test_input...."),\n }\n'} == {'test_input...."),\n }\n'} Differing items: {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...1.read_text().replace(r"\\r\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\r\\n", r"\\n"),\n }\n'} != {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...: file1.read_text().replace(r"\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\n", r"\\n"),\n }\n'} Full diff: { 'test_input.py': 'import datetime\n' '\n' 'from pathlib import Path\n' '\n' 'import numpy as np\n' 'import pytest\n' '\n' 'import panel as pn\n' '\n' 'pytest.importorskip("playwright")\n' '\n' 'from playwright.sync_api import Error, expect\n' '\n' 'from panel.tests.util import serve_component, wait_until\n' 'from panel.widgets import (\n' ' DatetimePicker, DatetimeRangePicker, TextAreaInput, ' 'TextInput,\n' ')\n' '\n' 'pytestmark = pytest.mark.ui\n' '\n' '\n' '@pytest.fixture\n' 'def weekdays_as_str():\n' " weekdays_str = '''\n" ' Sun\n' ' Mon\n' ' Tue\n' ' Wed\n' ' Thu\n' ' Fri\n' ' Sat\n' " '''\n" ' return weekdays_str\n' '\n' '\n' '@pytest.fixture\n' 'def months_as_str():\n' " months_str = '''\n" ' January\n' ' February\n' ' March\n' ' April\n' ' May\n' ' June\n' ' July\n' ' August\n' ' September\n' ' October\n' ' November\n' ' December\n' " '''\n" ' return months_str\n' '\n' '\n' '@pytest.fixture\n' 'def march_2021():\n' ' march_2021_days = [\n' ' 28, 1, 2, 3, 4, 5, 6, # 1st week\n' ' 7, 8, 9, 10, 11, 12, 13, # 2nd week\n' ' 14, 15, 16, 17, 18, 19, 20, # 3rd week\n' ' 21, 22, 23, 24, 25, 26, 27, # 4th week\n' ' 28, 29, 30, 31, 1, 2, 3, # 5th week\n' ' 4, 5, 6, 7, 8, 9, 10 # 6th week\n' ' ]\n' " march_2021_str = '\\n'.join([str(i) for i in " 'march_2021_days])\n' ' num_days = 42\n' ' num_prev_month_days = 1\n' ' num_next_month_days = 10\n' ' return march_2021_str, num_days, num_prev_month_days, ' 'num_next_month_days\n' '\n' '\n' '@pytest.fixture\n' 'def datetime_value_data():\n' ' year, month, day, ho

Check failure on line 736 in panel/tests/ui/widgets/test_input.py

View workflow job for this annotation

GitHub Actions / ui:test-ui:macos-latest

test_filedropper_text_file assert {'test_input...."),\n }\n'} == {'test_input...."),\n }\n'} Differing items: {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...1.read_text().replace(r"\\r\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\r\\n", r"\\n"),\n }\n'} != {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...: file1.read_text().replace(r"\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\n", r"\\n"),\n }\n'} Full diff: { 'test_input.py': 'import datetime\n' '\n' 'from pathlib import Path\n' '\n' 'import numpy as np\n' 'import pytest\n' '\n' 'import panel as pn\n' '\n' 'pytest.importorskip("playwright")\n' '\n' 'from playwright.sync_api import Error, expect\n' '\n' 'from panel.tests.util import serve_component, wait_until\n' 'from panel.widgets import (\n' ' DatetimePicker, DatetimeRangePicker, TextAreaInput, ' 'TextInput,\n' ')\n' '\n' 'pytestmark = pytest.mark.ui\n' '\n' '\n' '@pytest.fixture\n' 'def weekdays_as_str():\n' " weekdays_str = '''\n" ' Sun\n' ' Mon\n' ' Tue\n' ' Wed\n' ' Thu\n' ' Fri\n' ' Sat\n' " '''\n" ' return weekdays_str\n' '\n' '\n' '@pytest.fixture\n' 'def months_as_str():\n' " months_str = '''\n" ' January\n' ' February\n' ' March\n' ' April\n' ' May\n' ' June\n' ' July\n' ' August\n' ' September\n' ' October\n' ' November\n' ' December\n' " '''\n" ' return months_str\n' '\n' '\n' '@pytest.fixture\n' 'def march_2021():\n' ' march_2021_days = [\n' ' 28, 1, 2, 3, 4, 5, 6, # 1st week\n' ' 7, 8, 9, 10, 11, 12, 13, # 2nd week\n' ' 14, 15, 16, 17, 18, 19, 20, # 3rd week\n' ' 21, 22, 23, 24, 25, 26, 27, # 4th week\n' ' 28, 29, 30, 31, 1, 2, 3, # 5th week\n' ' 4, 5, 6, 7, 8, 9, 10 # 6th week\n' ' ]\n' " march_2021_str = '\\n'.join([str(i) for i in " 'march_2021_days])\n' ' num_days = 42\n' ' num_prev_month_days = 1\n' ' num_next_month_days = 10\n' ' return march_2021_str, num_days, num_prev_month_days, ' 'num_next_month_days\n' '\n' '\n' '@pytest.fixture\n' 'def datetime_value_data():\n' ' year, month, day, ho

Check failure on line 736 in panel/tests/ui/widgets/test_input.py

View workflow job for this annotation

GitHub Actions / ui:test-ui:macos-latest

test_filedropper_text_file assert {'test_input...."),\n }\n'} == {'test_input...."),\n }\n'} Differing items: {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...1.read_text().replace(r"\\r\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\r\\n", r"\\n"),\n }\n'} != {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...: file1.read_text().replace(r"\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\n", r"\\n"),\n }\n'} Full diff: { 'test_input.py': 'import datetime\n' '\n' 'from pathlib import Path\n' '\n' 'import numpy as np\n' 'import pytest\n' '\n' 'import panel as pn\n' '\n' 'pytest.importorskip("playwright")\n' '\n' 'from playwright.sync_api import Error, expect\n' '\n' 'from panel.tests.util import serve_component, wait_until\n' 'from panel.widgets import (\n' ' DatetimePicker, DatetimeRangePicker, TextAreaInput, ' 'TextInput,\n' ')\n' '\n' 'pytestmark = pytest.mark.ui\n' '\n' '\n' '@pytest.fixture\n' 'def weekdays_as_str():\n' " weekdays_str = '''\n" ' Sun\n' ' Mon\n' ' Tue\n' ' Wed\n' ' Thu\n' ' Fri\n' ' Sat\n' " '''\n" ' return weekdays_str\n' '\n' '\n' '@pytest.fixture\n' 'def months_as_str():\n' " months_str = '''\n" ' January\n' ' February\n' ' March\n' ' April\n' ' May\n' ' June\n' ' July\n' ' August\n' ' September\n' ' October\n' ' November\n' ' December\n' " '''\n" ' return months_str\n' '\n' '\n' '@pytest.fixture\n' 'def march_2021():\n' ' march_2021_days = [\n' ' 28, 1, 2, 3, 4, 5, 6, # 1st week\n' ' 7, 8, 9, 10, 11, 12, 13, # 2nd week\n' ' 14, 15, 16, 17, 18, 19, 20, # 3rd week\n' ' 21, 22, 23, 24, 25, 26, 27, # 4th week\n' ' 28, 29, 30, 31, 1, 2, 3, # 5th week\n' ' 4, 5, 6, 7, 8, 9, 10 # 6th week\n' ' ]\n' " march_2021_str = '\\n'.join([str(i) for i in " 'march_2021_days])\n' ' num_days = 42\n' ' num_prev_month_days = 1\n' ' num_next_month_days = 10\n' ' return march_2021_str, num_days, num_prev_month_days, ' 'num_next_month_days\n' '\n' '\n' '@pytest.fixture\n' 'def datetime_value_data():\n' ' year, month, day, ho
file.name: file.read_text().replace(r"\r\n", r"\n"),
}

def test_filedropper_multiple_file_error(page):
widget = pn.widgets.FileDropper()
Expand All @@ -754,5 +756,6 @@ def test_filedropper_multiple_files(page):

wait_until(lambda: len(widget.value) == 2)
assert widget.value == {

Check failure on line 758 in panel/tests/ui/widgets/test_input.py

View workflow job for this annotation

GitHub Actions / ui:test-ui:ubuntu-latest

test_filedropper_multiple_files assert {'__init__.py..."),\n }\n'} == {'__init__.py..."),\n }\n'} Omitting 1 identical items, use -vv to show Differing items: {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...1.read_text().replace(r"\\r\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\r\\n", r"\\n"),\n }\n'} != {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...: file1.read_text().replace(r"\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\n", r"\\n"),\n }\n'} Full diff: { '__init__.py': '', 'test_input.py': 'import datetime\n' '\n' 'from pathlib import Path\n' '\n' 'import numpy as np\n' 'import pytest\n' '\n' 'import panel as pn\n' '\n' 'pytest.importorskip("playwright")\n' '\n' 'from playwright.sync_api import Error, expect\n' '\n' 'from panel.tests.util import serve_component, wait_until\n' 'from panel.widgets import (\n' ' DatetimePicker, DatetimeRangePicker, TextAreaInput, ' 'TextInput,\n' ')\n' '\n' 'pytestmark = pytest.mark.ui\n' '\n' '\n' '@pytest.fixture\n' 'def weekdays_as_str():\n' " weekdays_str = '''\n" ' Sun\n' ' Mon\n' ' Tue\n' ' Wed\n' ' Thu\n' ' Fri\n' ' Sat\n' " '''\n" ' return weekdays_str\n' '\n' '\n' '@pytest.fixture\n' 'def months_as_str():\n' " months_str = '''\n" ' January\n' ' February\n' ' March\n' ' April\n' ' May\n' ' June\n' ' July\n' ' August\n' ' September\n' ' October\n' ' November\n' ' December\n' " '''\n" ' return months_str\n' '\n' '\n' '@pytest.fixture\n' 'def march_2021():\n' ' march_2021_days = [\n' ' 28, 1, 2, 3, 4, 5, 6, # 1st week\n' ' 7, 8, 9, 10, 11, 12, 13, # 2nd week\n' ' 14, 15, 16, 17, 18, 19, 20, # 3rd week\n' ' 21, 22, 23, 24, 25, 26, 27, # 4th week\n' ' 28, 29, 30, 31, 1, 2, 3, # 5th week\n' ' 4, 5, 6, 7, 8, 9, 10 # 6th week\n' ' ]\n' " march_2021_str = '\\n'.join([str(i) for i in " 'march_2021_days])\n' ' num_days = 42\n' ' num_prev_month_days = 1\n' ' num_next_month_days = 10\n' ' return march_2021_str, num_days, num_prev_month_days, ' 'num_next_month_days\n' '\n' '\n' '@pytest.fixture\n' 'de

Check failure on line 758 in panel/tests/ui/widgets/test_input.py

View workflow job for this annotation

GitHub Actions / ui:test-ui:ubuntu-latest

test_filedropper_multiple_files assert {'__init__.py..."),\n }\n'} == {'__init__.py..."),\n }\n'} Omitting 1 identical items, use -vv to show Differing items: {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...1.read_text().replace(r"\\r\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\r\\n", r"\\n"),\n }\n'} != {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...: file1.read_text().replace(r"\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\n", r"\\n"),\n }\n'} Full diff: { '__init__.py': '', 'test_input.py': 'import datetime\n' '\n' 'from pathlib import Path\n' '\n' 'import numpy as np\n' 'import pytest\n' '\n' 'import panel as pn\n' '\n' 'pytest.importorskip("playwright")\n' '\n' 'from playwright.sync_api import Error, expect\n' '\n' 'from panel.tests.util import serve_component, wait_until\n' 'from panel.widgets import (\n' ' DatetimePicker, DatetimeRangePicker, TextAreaInput, ' 'TextInput,\n' ')\n' '\n' 'pytestmark = pytest.mark.ui\n' '\n' '\n' '@pytest.fixture\n' 'def weekdays_as_str():\n' " weekdays_str = '''\n" ' Sun\n' ' Mon\n' ' Tue\n' ' Wed\n' ' Thu\n' ' Fri\n' ' Sat\n' " '''\n" ' return weekdays_str\n' '\n' '\n' '@pytest.fixture\n' 'def months_as_str():\n' " months_str = '''\n" ' January\n' ' February\n' ' March\n' ' April\n' ' May\n' ' June\n' ' July\n' ' August\n' ' September\n' ' October\n' ' November\n' ' December\n' " '''\n" ' return months_str\n' '\n' '\n' '@pytest.fixture\n' 'def march_2021():\n' ' march_2021_days = [\n' ' 28, 1, 2, 3, 4, 5, 6, # 1st week\n' ' 7, 8, 9, 10, 11, 12, 13, # 2nd week\n' ' 14, 15, 16, 17, 18, 19, 20, # 3rd week\n' ' 21, 22, 23, 24, 25, 26, 27, # 4th week\n' ' 28, 29, 30, 31, 1, 2, 3, # 5th week\n' ' 4, 5, 6, 7, 8, 9, 10 # 6th week\n' ' ]\n' " march_2021_str = '\\n'.join([str(i) for i in " 'march_2021_days])\n' ' num_days = 42\n' ' num_prev_month_days = 1\n' ' num_next_month_days = 10\n' ' return march_2021_str, num_days, num_prev_month_days, ' 'num_next_month_days\n' '\n' '\n' '@pytest.fixture\n' 'de

Check failure on line 758 in panel/tests/ui/widgets/test_input.py

View workflow job for this annotation

GitHub Actions / ui:test-ui:ubuntu-latest

test_filedropper_multiple_files assert {'__init__.py..."),\n }\n'} == {'__init__.py..."),\n }\n'} Omitting 1 identical items, use -vv to show Differing items: {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...1.read_text().replace(r"\\r\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\r\\n", r"\\n"),\n }\n'} != {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...: file1.read_text().replace(r"\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\n", r"\\n"),\n }\n'} Full diff: { '__init__.py': '', 'test_input.py': 'import datetime\n' '\n' 'from pathlib import Path\n' '\n' 'import numpy as np\n' 'import pytest\n' '\n' 'import panel as pn\n' '\n' 'pytest.importorskip("playwright")\n' '\n' 'from playwright.sync_api import Error, expect\n' '\n' 'from panel.tests.util import serve_component, wait_until\n' 'from panel.widgets import (\n' ' DatetimePicker, DatetimeRangePicker, TextAreaInput, ' 'TextInput,\n' ')\n' '\n' 'pytestmark = pytest.mark.ui\n' '\n' '\n' '@pytest.fixture\n' 'def weekdays_as_str():\n' " weekdays_str = '''\n" ' Sun\n' ' Mon\n' ' Tue\n' ' Wed\n' ' Thu\n' ' Fri\n' ' Sat\n' " '''\n" ' return weekdays_str\n' '\n' '\n' '@pytest.fixture\n' 'def months_as_str():\n' " months_str = '''\n" ' January\n' ' February\n' ' March\n' ' April\n' ' May\n' ' June\n' ' July\n' ' August\n' ' September\n' ' October\n' ' November\n' ' December\n' " '''\n" ' return months_str\n' '\n' '\n' '@pytest.fixture\n' 'def march_2021():\n' ' march_2021_days = [\n' ' 28, 1, 2, 3, 4, 5, 6, # 1st week\n' ' 7, 8, 9, 10, 11, 12, 13, # 2nd week\n' ' 14, 15, 16, 17, 18, 19, 20, # 3rd week\n' ' 21, 22, 23, 24, 25, 26, 27, # 4th week\n' ' 28, 29, 30, 31, 1, 2, 3, # 5th week\n' ' 4, 5, 6, 7, 8, 9, 10 # 6th week\n' ' ]\n' " march_2021_str = '\\n'.join([str(i) for i in " 'march_2021_days])\n' ' num_days = 42\n' ' num_prev_month_days = 1\n' ' num_next_month_days = 10\n' ' return march_2021_str, num_days, num_prev_month_days, ' 'num_next_month_days\n' '\n' '\n' '@pytest.fixture\n' 'de

Check failure on line 758 in panel/tests/ui/widgets/test_input.py

View workflow job for this annotation

GitHub Actions / ui:test-ui:ubuntu-latest

test_filedropper_multiple_files assert {'__init__.py..."),\n }\n'} == {'__init__.py..."),\n }\n'} Omitting 1 identical items, use -vv to show Differing items: {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...1.read_text().replace(r"\\r\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\r\\n", r"\\n"),\n }\n'} != {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...: file1.read_text().replace(r"\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\n", r"\\n"),\n }\n'} Full diff: { '__init__.py': '', 'test_input.py': 'import datetime\n' '\n' 'from pathlib import Path\n' '\n' 'import numpy as np\n' 'import pytest\n' '\n' 'import panel as pn\n' '\n' 'pytest.importorskip("playwright")\n' '\n' 'from playwright.sync_api import Error, expect\n' '\n' 'from panel.tests.util import serve_component, wait_until\n' 'from panel.widgets import (\n' ' DatetimePicker, DatetimeRangePicker, TextAreaInput, ' 'TextInput,\n' ')\n' '\n' 'pytestmark = pytest.mark.ui\n' '\n' '\n' '@pytest.fixture\n' 'def weekdays_as_str():\n' " weekdays_str = '''\n" ' Sun\n' ' Mon\n' ' Tue\n' ' Wed\n' ' Thu\n' ' Fri\n' ' Sat\n' " '''\n" ' return weekdays_str\n' '\n' '\n' '@pytest.fixture\n' 'def months_as_str():\n' " months_str = '''\n" ' January\n' ' February\n' ' March\n' ' April\n' ' May\n' ' June\n' ' July\n' ' August\n' ' September\n' ' October\n' ' November\n' ' December\n' " '''\n" ' return months_str\n' '\n' '\n' '@pytest.fixture\n' 'def march_2021():\n' ' march_2021_days = [\n' ' 28, 1, 2, 3, 4, 5, 6, # 1st week\n' ' 7, 8, 9, 10, 11, 12, 13, # 2nd week\n' ' 14, 15, 16, 17, 18, 19, 20, # 3rd week\n' ' 21, 22, 23, 24, 25, 26, 27, # 4th week\n' ' 28, 29, 30, 31, 1, 2, 3, # 5th week\n' ' 4, 5, 6, 7, 8, 9, 10 # 6th week\n' ' ]\n' " march_2021_str = '\\n'.join([str(i) for i in " 'march_2021_days])\n' ' num_days = 42\n' ' num_prev_month_days = 1\n' ' num_next_month_days = 10\n' ' return march_2021_str, num_days, num_prev_month_days, ' 'num_next_month_days\n' '\n' '\n' '@pytest.fixture\n' 'de

Check failure on line 758 in panel/tests/ui/widgets/test_input.py

View workflow job for this annotation

GitHub Actions / ui:test-ui:macos-latest

test_filedropper_multiple_files assert {'__init__.py..."),\n }\n'} == {'__init__.py..."),\n }\n'} Omitting 1 identical items, use -vv to show Differing items: {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...1.read_text().replace(r"\\r\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\r\\n", r"\\n"),\n }\n'} != {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...: file1.read_text().replace(r"\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\n", r"\\n"),\n }\n'} Full diff: { '__init__.py': '', 'test_input.py': 'import datetime\n' '\n' 'from pathlib import Path\n' '\n' 'import numpy as np\n' 'import pytest\n' '\n' 'import panel as pn\n' '\n' 'pytest.importorskip("playwright")\n' '\n' 'from playwright.sync_api import Error, expect\n' '\n' 'from panel.tests.util import serve_component, wait_until\n' 'from panel.widgets import (\n' ' DatetimePicker, DatetimeRangePicker, TextAreaInput, ' 'TextInput,\n' ')\n' '\n' 'pytestmark = pytest.mark.ui\n' '\n' '\n' '@pytest.fixture\n' 'def weekdays_as_str():\n' " weekdays_str = '''\n" ' Sun\n' ' Mon\n' ' Tue\n' ' Wed\n' ' Thu\n' ' Fri\n' ' Sat\n' " '''\n" ' return weekdays_str\n' '\n' '\n' '@pytest.fixture\n' 'def months_as_str():\n' " months_str = '''\n" ' January\n' ' February\n' ' March\n' ' April\n' ' May\n' ' June\n' ' July\n' ' August\n' ' September\n' ' October\n' ' November\n' ' December\n' " '''\n" ' return months_str\n' '\n' '\n' '@pytest.fixture\n' 'def march_2021():\n' ' march_2021_days = [\n' ' 28, 1, 2, 3, 4, 5, 6, # 1st week\n' ' 7, 8, 9, 10, 11, 12, 13, # 2nd week\n' ' 14, 15, 16, 17, 18, 19, 20, # 3rd week\n' ' 21, 22, 23, 24, 25, 26, 27, # 4th week\n' ' 28, 29, 30, 31, 1, 2, 3, # 5th week\n' ' 4, 5, 6, 7, 8, 9, 10 # 6th week\n' ' ]\n' " march_2021_str = '\\n'.join([str(i) for i in " 'march_2021_days])\n' ' num_days = 42\n' ' num_prev_month_days = 1\n' ' num_next_month_days = 10\n' ' return march_2021_str, num_days, num_prev_month_days, ' 'num_next_month_days\n' '\n' '\n' '@pytest.fixture\n' 'de

Check failure on line 758 in panel/tests/ui/widgets/test_input.py

View workflow job for this annotation

GitHub Actions / ui:test-ui:macos-latest

test_filedropper_multiple_files assert {'__init__.py..."),\n }\n'} == {'__init__.py..."),\n }\n'} Omitting 1 identical items, use -vv to show Differing items: {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...1.read_text().replace(r"\\r\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\r\\n", r"\\n"),\n }\n'} != {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...: file1.read_text().replace(r"\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\n", r"\\n"),\n }\n'} Full diff: { '__init__.py': '', 'test_input.py': 'import datetime\n' '\n' 'from pathlib import Path\n' '\n' 'import numpy as np\n' 'import pytest\n' '\n' 'import panel as pn\n' '\n' 'pytest.importorskip("playwright")\n' '\n' 'from playwright.sync_api import Error, expect\n' '\n' 'from panel.tests.util import serve_component, wait_until\n' 'from panel.widgets import (\n' ' DatetimePicker, DatetimeRangePicker, TextAreaInput, ' 'TextInput,\n' ')\n' '\n' 'pytestmark = pytest.mark.ui\n' '\n' '\n' '@pytest.fixture\n' 'def weekdays_as_str():\n' " weekdays_str = '''\n" ' Sun\n' ' Mon\n' ' Tue\n' ' Wed\n' ' Thu\n' ' Fri\n' ' Sat\n' " '''\n" ' return weekdays_str\n' '\n' '\n' '@pytest.fixture\n' 'def months_as_str():\n' " months_str = '''\n" ' January\n' ' February\n' ' March\n' ' April\n' ' May\n' ' June\n' ' July\n' ' August\n' ' September\n' ' October\n' ' November\n' ' December\n' " '''\n" ' return months_str\n' '\n' '\n' '@pytest.fixture\n' 'def march_2021():\n' ' march_2021_days = [\n' ' 28, 1, 2, 3, 4, 5, 6, # 1st week\n' ' 7, 8, 9, 10, 11, 12, 13, # 2nd week\n' ' 14, 15, 16, 17, 18, 19, 20, # 3rd week\n' ' 21, 22, 23, 24, 25, 26, 27, # 4th week\n' ' 28, 29, 30, 31, 1, 2, 3, # 5th week\n' ' 4, 5, 6, 7, 8, 9, 10 # 6th week\n' ' ]\n' " march_2021_str = '\\n'.join([str(i) for i in " 'march_2021_days])\n' ' num_days = 42\n' ' num_prev_month_days = 1\n' ' num_next_month_days = 10\n' ' return march_2021_str, num_days, num_prev_month_days, ' 'num_next_month_days\n' '\n' '\n' '@pytest.fixture\n' 'de

Check failure on line 758 in panel/tests/ui/widgets/test_input.py

View workflow job for this annotation

GitHub Actions / ui:test-ui:macos-latest

test_filedropper_multiple_files assert {'__init__.py..."),\n }\n'} == {'__init__.py..."),\n }\n'} Omitting 1 identical items, use -vv to show Differing items: {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...1.read_text().replace(r"\\r\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\r\\n", r"\\n"),\n }\n'} != {'test_input.py': 'import datetime\n\nfrom pathlib import Path\n\nimport numpy as np\nimport pytest\n\nimport panel as...: file1.read_text().replace(r"\\n", r"\\n"),\n file2.name: file2.read_text().replace(r"\\n", r"\\n"),\n }\n'} Full diff: { '__init__.py': '', 'test_input.py': 'import datetime\n' '\n' 'from pathlib import Path\n' '\n' 'import numpy as np\n' 'import pytest\n' '\n' 'import panel as pn\n' '\n' 'pytest.importorskip("playwright")\n' '\n' 'from playwright.sync_api import Error, expect\n' '\n' 'from panel.tests.util import serve_component, wait_until\n' 'from panel.widgets import (\n' ' DatetimePicker, DatetimeRangePicker, TextAreaInput, ' 'TextInput,\n' ')\n' '\n' 'pytestmark = pytest.mark.ui\n' '\n' '\n' '@pytest.fixture\n' 'def weekdays_as_str():\n' " weekdays_str = '''\n" ' Sun\n' ' Mon\n' ' Tue\n' ' Wed\n' ' Thu\n' ' Fri\n' ' Sat\n' " '''\n" ' return weekdays_str\n' '\n' '\n' '@pytest.fixture\n' 'def months_as_str():\n' " months_str = '''\n" ' January\n' ' February\n' ' March\n' ' April\n' ' May\n' ' June\n' ' July\n' ' August\n' ' September\n' ' October\n' ' November\n' ' December\n' " '''\n" ' return months_str\n' '\n' '\n' '@pytest.fixture\n' 'def march_2021():\n' ' march_2021_days = [\n' ' 28, 1, 2, 3, 4, 5, 6, # 1st week\n' ' 7, 8, 9, 10, 11, 12, 13, # 2nd week\n' ' 14, 15, 16, 17, 18, 19, 20, # 3rd week\n' ' 21, 22, 23, 24, 25, 26, 27, # 4th week\n' ' 28, 29, 30, 31, 1, 2, 3, # 5th week\n' ' 4, 5, 6, 7, 8, 9, 10 # 6th week\n' ' ]\n' " march_2021_str = '\\n'.join([str(i) for i in " 'march_2021_days])\n' ' num_days = 42\n' ' num_prev_month_days = 1\n' ' num_next_month_days = 10\n' ' return march_2021_str, num_days, num_prev_month_days, ' 'num_next_month_days\n' '\n' '\n' '@pytest.fixture\n' 'de
file1.name: file1.read_text(), file2.name: file2.read_text()
file1.name: file1.read_text().replace(r"\r\n", r"\n"),
file2.name: file2.read_text().replace(r"\r\n", r"\n"),
}

0 comments on commit ce1b59f

Please sign in to comment.