| 108 | |
| 109 | |
| 110 | class TestPatchPolars(TestCase): |
| 111 | def setUp(self): |
| 112 | if sys.platform == 'win32' and sys.version_info[:2] == (3, 9): |
| 113 | raise SkipTest('stack overflow error') |
| 114 | try: |
| 115 | import polars as pl # noqa |
| 116 | except ImportError: |
| 117 | raise SkipTest('Polars not available') |
| 118 | import hvplot.polars # noqa |
| 119 | |
| 120 | def test_polars_series_patched(self): |
| 121 | import polars as pl |
| 122 | |
| 123 | pseries = pl.Series([0, 1, 2]) |
| 124 | self.assertIsInstance(pseries.hvplot, hvPlotTabular) |
| 125 | |
| 126 | def test_polars_dataframe_patched(self): |
| 127 | import polars as pl |
| 128 | |
| 129 | pdf = pl.DataFrame({'x': [1, 3, 5], 'y': [2, 4, 6]}) |
| 130 | self.assertIsInstance(pdf.hvplot, hvPlotTabular) |
| 131 | |
| 132 | def test_polars_lazyframe_patched(self): |
| 133 | import polars as pl |
| 134 | |
| 135 | pldf = pl.LazyFrame({'x': [1, 3, 5], 'y': [2, 4, 6]}) |
| 136 | self.assertIsInstance(pldf.hvplot, hvPlotTabular) |
| 137 | |
| 138 | |
| 139 | class TestPatchDuckDB(TestCase): |
nothing calls this directly
no outgoing calls
no test coverage detected
searching dependent graphs…