Skip to content

Commit

Permalink
Updated plotly unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
jlstevens committed Jul 16, 2021
1 parent bb12d5e commit fecc3c6
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions holoviews/tests/plotting/plotly/testscatterplot.py
Original file line number Diff line number Diff line change
Expand Up @@ -112,16 +112,19 @@ def test_scatter_colors(self):
(0, 1, 'red'), (1, 2, 'green'), (2, 3, 'blue')
], vdims=['y', 'color']).options(color='color')
state = self._get_plot_state(scatter)
self.assertEqual(state['data'][1]['marker']['color'],
np.array(['red', 'green', 'blue']))
self.assertEqual(np.array_equal(state['data'][1]['marker']['color'],
np.array(['red', 'green', 'blue'])), True)


def test_scatter_markers(self):
scatter = Tiles('') * Scatter([
(0, 1, 'square'), (1, 2, 'circle'), (2, 3, 'triangle-up')
(0, 1, 'square'), (1, 2, 'circle'), (2, 3, 'triangle-up') #
], vdims=['y', 'marker']).options(marker='marker')
state = self._get_plot_state(scatter)
self.assertEqual(state['data'][1]['marker']['symbol'],
np.array(['square', 'circle', 'triangle-up']))
self.assertEqual(
np.array_equal(
state['data'][1]['marker']['symbol'],
np.array(['square', 'circle', 'triangle-up'])), True)

def test_scatter_selectedpoints(self):
scatter = Tiles('') * Scatter([
Expand Down

0 comments on commit fecc3c6

Please sign in to comment.