Skip to content

Commit

Permalink
Add test
Browse files Browse the repository at this point in the history
  • Loading branch information
hoxbro committed Jan 22, 2025
1 parent ebcf912 commit 55f871e
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions panel/tests/test_reactive.py
Original file line number Diff line number Diff line change
Expand Up @@ -808,3 +808,15 @@ def test_reactive_design_stylesheets_update(document, comm):

assert len(model.stylesheets) == 5
assert model.stylesheets[-1] == widget.stylesheets[0]


def test_reactive_attribute_no_name(document, comm):
# Regression: https://github.com/holoviz/panel/pull/7655
class CustomComponent(ReactiveHTML):
groups = param.ListSelector(default=["A"], objects=["A", "B"])
_scripts = {"groups": "console.log(data.groups)"}

component = CustomComponent()
component.get_root(document, comm)
# Should not error out
component.groups = []

0 comments on commit 55f871e

Please sign in to comment.