Skip to content

Commit d6d6b12

Browse files
committed
formatting
1 parent cce0132 commit d6d6b12

File tree

3 files changed

+32
-16
lines changed

3 files changed

+32
-16
lines changed

packages/installations/src/api/get-token.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,7 @@
1717

1818
import { getInstallationEntry } from '../helpers/get-installation-entry';
1919
import { refreshAuthToken } from '../helpers/refresh-auth-token';
20-
import {
21-
FirebaseInstallationsImpl
22-
} from '../interfaces/installation-impl';
20+
import { FirebaseInstallationsImpl } from '../interfaces/installation-impl';
2321
import { Installations } from '../interfaces/public-types';
2422

2523
/**

packages/installations/src/functions/create-installation-request.test.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,7 @@ import { FirebaseError } from '@firebase/util';
1919
import { expect } from 'chai';
2020
import { SinonStub, stub } from 'sinon';
2121
import { CreateInstallationResponse } from '../interfaces/api-response';
22-
import {
23-
FirebaseInstallationsImpl
24-
} from '../interfaces/installation-impl';
22+
import { FirebaseInstallationsImpl } from '../interfaces/installation-impl';
2523
import {
2624
InProgressInstallationEntry,
2725
RequestStatus

packages/installations/src/helpers/get-installation-entry.test.ts

Lines changed: 30 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,10 @@
1818
import { AssertionError, expect } from 'chai';
1919
import { SinonFakeTimers, SinonStub, stub, useFakeTimers } from 'sinon';
2020
import * as createInstallationRequestModule from '../functions/create-installation-request';
21-
import { AppConfig, FirebaseInstallationsImpl } from '../interfaces/installation-impl';
21+
import {
22+
AppConfig,
23+
FirebaseInstallationsImpl
24+
} from '../interfaces/installation-impl';
2225
import {
2326
InProgressInstallationEntry,
2427
RegisteredInstallationEntry,
@@ -172,8 +175,12 @@ describe('getInstallationEntry', () => {
172175
});
173176

174177
it('returns the same FID on subsequent calls', async () => {
175-
const { installationEntry: entry1 } = await getInstallationEntry(fakeInstallations);
176-
const { installationEntry: entry2 } = await getInstallationEntry(fakeInstallations);
178+
const { installationEntry: entry1 } = await getInstallationEntry(
179+
fakeInstallations
180+
);
181+
const { installationEntry: entry2 } = await getInstallationEntry(
182+
fakeInstallations
183+
);
177184
expect(entry1.fid).to.equal(entry2.fid);
178185
});
179186

@@ -210,7 +217,9 @@ describe('getInstallationEntry', () => {
210217
it('returns a new unregistered InstallationEntry if app is offline', async () => {
211218
stub(navigator, 'onLine').value(false);
212219

213-
const { installationEntry } = await getInstallationEntry(fakeInstallations);
220+
const { installationEntry } = await getInstallationEntry(
221+
fakeInstallations
222+
);
214223

215224
expect(installationEntry).to.deep.equal({
216225
fid: FID,
@@ -268,7 +277,8 @@ describe('getInstallationEntry', () => {
268277
// FID generation fails.
269278
generateInstallationEntrySpy.returns(generateFidModule.INVALID_FID);
270279

271-
const getInstallationEntryPromise = getInstallationEntry(fakeInstallations);
280+
const getInstallationEntryPromise =
281+
getInstallationEntry(fakeInstallations);
272282

273283
const { installationEntry, registrationPromise } =
274284
await getInstallationEntryPromise;
@@ -308,7 +318,9 @@ describe('getInstallationEntry', () => {
308318
it('returns the same InstallationEntry if the app is offline', async () => {
309319
stub(navigator, 'onLine').value(false);
310320

311-
const { installationEntry } = await getInstallationEntry(fakeInstallations);
321+
const { installationEntry } = await getInstallationEntry(
322+
fakeInstallations
323+
);
312324

313325
expect(installationEntry).to.deep.equal({
314326
fid: FID,
@@ -331,7 +343,9 @@ describe('getInstallationEntry', () => {
331343
it("returns the same InstallationEntry if the request hasn't timed out", async () => {
332344
clock.now = 1_001_000; // One second after the request was initiated.
333345

334-
const { installationEntry } = await getInstallationEntry(fakeInstallations);
346+
const { installationEntry } = await getInstallationEntry(
347+
fakeInstallations
348+
);
335349

336350
expect(installationEntry).to.deep.equal({
337351
fid: FID,
@@ -420,7 +434,9 @@ describe('getInstallationEntry', () => {
420434
it('returns a new pending InstallationEntry and triggers createInstallation if the request had already timed out', async () => {
421435
clock.now = 1_015_000; // Fifteen seconds after the request was initiated.
422436

423-
const { installationEntry } = await getInstallationEntry(fakeInstallations);
437+
const { installationEntry } = await getInstallationEntry(
438+
fakeInstallations
439+
);
424440

425441
expect(installationEntry).to.deep.equal({
426442
fid: FID,
@@ -434,7 +450,9 @@ describe('getInstallationEntry', () => {
434450
stub(navigator, 'onLine').value(false);
435451
clock.now = 1_015_000; // Fifteen seconds after the request was initiated.
436452

437-
const { installationEntry } = await getInstallationEntry(fakeInstallations);
453+
const { installationEntry } = await getInstallationEntry(
454+
fakeInstallations
455+
);
438456

439457
expect(installationEntry).to.deep.equal({
440458
fid: FID,
@@ -456,7 +474,9 @@ describe('getInstallationEntry', () => {
456474
});
457475

458476
it('returns the InstallationEntry from the database', async () => {
459-
const { installationEntry } = await getInstallationEntry(fakeInstallations);
477+
const { installationEntry } = await getInstallationEntry(
478+
fakeInstallations
479+
);
460480

461481
expect(installationEntry).to.deep.equal({
462482
fid: FID,

0 commit comments

Comments
 (0)