Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -344,7 +344,7 @@ describe('OrganizationCreditActivityScreen pagination', () => {
const texts = await renderScreen();

expect(texts).toContain('Top-up');
expect(texts).toContain("Couldn't load more.");
expect(texts).toContain("Couldn't load more");
expect(texts).not.toContain('Older credit activity is available.');

const retry = buttons.rendered.find(button => button.accessibilityLabel === 'Retry');
Expand Down Expand Up @@ -383,7 +383,7 @@ describe('OrganizationCreditActivityScreen pagination', () => {

expect(texts).toContain('Top-up');
expect(texts).toContain('Older credit activity is available.');
expect(texts).not.toContain("Couldn't load more.");
expect(texts).not.toContain("Couldn't load more");
expect(buttons.rendered.some(button => button.accessibilityLabel === 'Load more')).toBe(true);
});
});
Original file line number Diff line number Diff line change
Expand Up @@ -331,7 +331,7 @@ describe('OrganizationInvoicesScreen pagination', () => {
const texts = await renderScreen();

expect(texts).toContain('INV-0001');
expect(texts).toContain("Couldn't load more.");
expect(texts).toContain("Couldn't load more");
expect(texts).not.toContain('Older invoices are available.');

const retry = buttons.rendered.find(button => button.accessibilityLabel === 'Retry');
Expand Down Expand Up @@ -370,7 +370,7 @@ describe('OrganizationInvoicesScreen pagination', () => {

expect(texts).toContain('INV-0001');
expect(texts).toContain('Older invoices are available.');
expect(texts).not.toContain("Couldn't load more.");
expect(texts).not.toContain("Couldn't load more");
expect(buttons.rendered.some(button => button.accessibilityLabel === 'Load more')).toBe(true);
});
});
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ export function staleHeadRejectionMessage(error: unknown): string | null {
* through the existing term-parameterized key; GitHub keeps the exact
* pre-s6 copy.
*/
export function mergeForbiddenCopy(
function mergeForbiddenCopy(
platform: ProviderPrPlatform | undefined,
t: ReturnType<typeof useTranslation>['t']
): string {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ describe('useSettingsBackGuard', () => {
});
});

it('shows Save / Discard / Keep Editing for a dirty-valid screen', () => {
it('shows Save / Discard / Keep editing for a dirty-valid screen', () => {
const { renderer } = mountGuard(true, true, noOpSave);

triggerPreventRemove();
Expand All @@ -141,20 +141,20 @@ describe('useSettingsBackGuard', () => {
expect(lastAlertButtons()?.map(button => button.text)).toEqual([
'Save changes',
'Discard',
'Keep Editing',
'Keep editing',
]);

act(() => {
renderer.unmount();
});
});

it('shows Discard / Keep Editing for a dirty-invalid screen', () => {
it('shows Discard / Keep editing for a dirty-invalid screen', () => {
const { renderer } = mountGuard(true, false, noOpSave);

triggerPreventRemove();
expect(alertMock).toHaveBeenCalledTimes(1);
expect(lastAlertButtons()?.map(button => button.text)).toEqual(['Discard', 'Keep Editing']);
expect(lastAlertButtons()?.map(button => button.text)).toEqual(['Discard', 'Keep editing']);

act(() => {
renderer.unmount();
Expand Down Expand Up @@ -233,14 +233,14 @@ describe('useSettingsBackGuard', () => {
});
});

it('Keep Editing leaves the screen untouched', () => {
it('Keep editing leaves the screen untouched', () => {
const onSave = vi.fn(async () => {
await Promise.resolve();
});
const { renderer } = mountGuard(true, true, onSave);
triggerPreventRemove();

const keep = lastAlertButtons()?.find(button => button.text === 'Keep Editing');
const keep = lastAlertButtons()?.find(button => button.text === 'Keep editing');
// The cancel button carries no handler: dismissing it must not save or leave.
expect(keep?.onPress).toBeUndefined();
expect(onSave).not.toHaveBeenCalled();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import { toast } from 'sonner-native';

import { useTRPC } from '@/lib/trpc';

export type ProviderConnectionPlatform = 'gitlab' | 'bitbucket';
type ProviderConnectionPlatform = 'gitlab' | 'bitbucket';

export type CheckProviderConnectionInput = {
platform: ProviderConnectionPlatform;
Expand Down
4 changes: 2 additions & 2 deletions apps/mobile/src/lib/pr-review/use-pr-review-mutations.ts
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ export type SubmitReviewComment = NonNullable<SubmitReviewInput['comments']>[num
* user tapped, with `startLine` marking the first line of a multi-line
* range ending at `line`. Absent, the comment is a top-level note.
*/
export type ProviderCommentAnchor = {
type ProviderCommentAnchor = {
path: string;
side: 'LEFT' | 'RIGHT';
line: number;
Expand Down Expand Up @@ -216,7 +216,7 @@ export function formatPendingCommentBody(item: {
}

/** One anchored item in a provider `submitReview` batch (c3). */
export type ProviderSubmitReviewComment = ProviderCommentAnchor & { body: string };
type ProviderSubmitReviewComment = ProviderCommentAnchor & { body: string };

/**
* The provider `submitReview` intent the submit sheet builds: every pending
Expand Down
Loading