Replace _getChangeDetail with _reload

_getChangeDetail was performing an incomplete reload of the change,
_reload fetches all pertinent information.

Change-Id: Ib83c9a3b0976f07f972fbc9b24820525abc74ad5
This commit is contained in:
Kasper Nilsson
2016-12-07 11:33:05 -08:00
parent 9c6306532b
commit 8e2321c704
2 changed files with 2 additions and 1 deletions

View File

@@ -596,7 +596,7 @@
},
_switchToMostRecentPatchNum: function() {
this._getChangeDetail().then(function() {
this._reload().then(function() {
var patchNum = this._computeLatestPatchNum(this._allPatchSets);
if (patchNum !== this._patchRange.patchNum) {
this._changePatchNum(patchNum);

View File

@@ -97,6 +97,7 @@ limitations under the License.
actions: {},
};
sandbox.stub(element.$.actions, 'reload');
sandbox.stub(element.$.restAPI, '_getChangeDetail', function() {
// Mock change obj.
return Promise.resolve({