Skip to content

Commit

Permalink
ng: add plugin-id on tab for testability (tensorflow#3591)
Browse files Browse the repository at this point in the history
We would like our webdriver tests to be able to find these nodes without
inspecting the textNode (with plugin name as opposed to plugin id). This
change adds data attribute adds one.
  • Loading branch information
stephanwlee authored May 6, 2020
1 parent 243b234 commit 79182fa
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion tensorboard/webapp/header/plugin_selector_component.ng.html
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
<span
class="plugin-name"
(click)="onActivePluginSelection($event, plugin.id)"
[attr.data-plugin-id]="plugin.id"
>
{{plugin.tab_name}}
</span>
Expand All @@ -39,7 +40,11 @@
[value]="selectedPlugin"
(selectionChange)="onDisabledPluginSelectionChanged($event)"
>
<mat-option *ngFor="let plugin of disabledPlugins" [value]="plugin.id">
<mat-option
*ngFor="let plugin of disabledPlugins"
[value]="plugin.id"
[attr.data-plugin-id]="plugin.id"
>
{{ plugin.tab_name }}
</mat-option>
</mat-select>
Expand Down

0 comments on commit 79182fa

Please sign in to comment.