build(docs-infra): upgrade all JS dependencies to latest versions (#36837)

This commit upgrades all dependencies in `scripts-js/` to latest
versions and also includes all necessary code changes to ensure the
tests are passing with the new dependency versions.

PR Close #36837
This commit is contained in:
George Kalpakas
2020-05-02 16:14:05 +03:00
committed by Alex Rickabaugh
parent 333abf16e4
commit eef01160f4
12 changed files with 1054 additions and 1649 deletions

View File

@ -51,7 +51,10 @@ describe('BuildVerifier', () => {
describe('getSignificantFilesChanged', () => {
it('should return false if none of the fetched files match the given pattern', async () => {
const fetchFilesSpy = spyOn(prs, 'fetchFiles');
fetchFilesSpy.and.callFake(() => Promise.resolve([{filename: 'a/b/c'}, {filename: 'd/e/f'}]));
fetchFilesSpy.and.callFake(() => Promise.resolve([
{filename: 'a/b/c', sha: 'a1'},
{filename: 'd/e/f', sha: 'b2'},
]));
expect(await bv.getSignificantFilesChanged(777, /^x/)).toEqual(false);
expect(fetchFilesSpy).toHaveBeenCalledWith(777);