Merge branch 'stable-2.16'
* stable-2.16:
Fix IAE when listing reviewers of change that has reviewers by email
BugFix: Add documentation for 'read as' capability
Fix assignee getting the owner's status on change list
Change-Id: Idc07fa417d75eeb8d5944cf1fc8af353d8736650
diff --git a/Documentation/access-control.txt b/Documentation/access-control.txt
index 13e3a53..516cf13 100644
--- a/Documentation/access-control.txt
+++ b/Documentation/access-control.txt
@@ -1362,6 +1362,12 @@
command, but also to the web UI results pagination size.
+[[capability_readAs]]
+=== Read As
+
+Allow users to impersonate any user to see which refs they can read.
+
+
[[capability_runAs]]
=== Run As
diff --git a/polygerrit-ui/app/elements/change-list/gr-change-list-item/gr-change-list-item.html b/polygerrit-ui/app/elements/change-list/gr-change-list-item/gr-change-list-item.html
index 9a3fc03..8c152b6 100644
--- a/polygerrit-ui/app/elements/change-list/gr-change-list-item/gr-change-list-item.html
+++ b/polygerrit-ui/app/elements/change-list/gr-change-list-item/gr-change-list-item.html
@@ -165,8 +165,9 @@
hidden$="[[isColumnHidden('Assignee', visibleChangeTableColumns)]]">
<template is="dom-if" if="[[change.assignee]]">
<gr-account-link
+ id="assigneeAccountLink"
account="[[change.assignee]]"
- additional-text="[[_computeAccountStatusString(change.owner)]]"></gr-account-link>
+ additional-text="[[_computeAccountStatusString(change.assignee)]]"></gr-account-link>
</template>
<template is="dom-if" if="[[!change.assignee]]">
<span class="placeholder">--</span>
diff --git a/polygerrit-ui/app/elements/change-list/gr-change-list-item/gr-change-list-item_test.html b/polygerrit-ui/app/elements/change-list/gr-change-list-item/gr-change-list-item_test.html
index aaad362..3637653 100644
--- a/polygerrit-ui/app/elements/change-list/gr-change-list-item/gr-change-list-item_test.html
+++ b/polygerrit-ui/app/elements/change-list/gr-change-list-item/gr-change-list-item_test.html
@@ -182,10 +182,13 @@
element.change = {
assignee: {
name: 'test',
+ status: 'test',
},
};
flushAsynchronousOperations();
assert.isOk(element.$$('.assignee gr-account-link'));
+ assert.equal(Polymer.dom(element.root)
+ .querySelector('#assigneeAccountLink').additionalText, '(test)');
});
test('_computeAccountStatusString', () => {