8000 Drop `pointcloud` and `heatmapgl` from plotly.py API and update plotly.js bundle from master by archmoj · Pull Request #4815 · plotly/plotly.py · GitHub
[go: up one dir, main page]

Skip to content

Drop pointcloud and heatmapgl from plotly.py API and update plotly.js bundle from master #4815

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

Merged
merged 5 commits into from
Oct 22, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
adjust tests
  • Loading branch information
archmoj committed Oct 22, 2024
commit 4094ffc6ddb73bad0d3eb9e827be15dbeb86121d
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ def test_multi_prop_callback_on_assignment_layout_nested(self):
fn_layout = MagicMock()

# Register callback on change to family property under title_font
self.figure.layout.xaxis.title_font.on_change(fn_title_font, "family")
self.figure.layout.xaxis.title.font.on_change(fn_title_font, "family")

# Register callback on the range and title_font.family properties
# under xaxis
Expand All @@ -106,7 +106,7 @@ def test_multi_prop_callback_on_assignment_layout_nested(self):
# Register callback on xaxis object itself
self.figure.layout.on_change(fn_layout, "xaxis")

# Assign a new xaxis range and title_font.family
# Assign a new xaxis range and title.font.family
self.figure.layout.xaxis.title.font.family = "courier"

# Check that all callbacks were executed once
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -118,31 +118,6 @@ def test_title_as_string_layout(self):
{"type": "pie", "title": {"text": "A title 2", "font": {"size": 23}}},
)

def test_legacy_title_props_remapped(self):

# plain Layout
obj = go.Layout()
self.assertIs(obj.title_font, obj.title.font)
self.assertIsNone(obj.title.font.family)

# Set title_font in constructor
obj = go.Layout(title_font={"family": "Courier"})
self.assertIs(obj.title_font, obj.title.font)
self.assertEqual(obj.title_font.family, "Courier")
self.assertEqual(obj.title.font.family, "Courier")

# Property assignment
obj = go.Layout()
obj.title_font.family = "Courier"
self.assertIs(obj.title_font, obj.title.font)
self.assertEqual(obj["title_font.family"], "Courier")
self.assertEqual(obj.title.font.family, "Courier")

# In/Iter
self.assertIn("title_font", obj)
self.assertIn("title_font.family", obj)
self.assertIn("title_font", iter(obj))


class TestPop(TestCase):
def setUp(self):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,9 @@ def test_toplevel_item(self):
assert d1 == d2

def test_nested_attr(self):
assert self.scatter.marker.colorbar.title_font.family is None
self.scatter.marker.colorbar.title_font.family = "courier"
assert self.scatter.marker.colorbar.title_font.family == "courier"
assert self.scatter.marker.colorbar.title.font.family is None
self.scatter.marker.colorbar.title.font.family = "courier"
assert self.scatter.marker.colorbar.title.font.family == "courier"
d1, d2 = strip_dict_params(self.scatter, self.expected_nested)
assert d1 == d2

Expand Down
0