Export/import attachments in integration tests

Co-authored-by: Fedor Indutny <79877362+indutny-signal@users.noreply.github.com>
This commit is contained in:
automated-signal 2024-10-15 15:15:05 -05:00 committed by GitHub
parent 850b78042b
commit 6859b1a220
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
21 changed files with 292 additions and 116 deletions

View file

@ -5,6 +5,7 @@ import React from 'react';
import type { Meta, StoryFn } from '@storybook/react';
import { action } from '@storybook/addon-actions';
import { setupI18n } from '../../util/setupI18n';
import { InstallScreenBackupStep } from '../../types/InstallScreen';
import enMessages from '../../../_locales/en/messages.json';
import type { PropsType } from './InstallScreenBackupImportStep';
import { InstallScreenBackupImportStep } from './InstallScreenBackupImportStep';
@ -27,25 +28,36 @@ const Template: StoryFn<PropsType> = (args: PropsType) => (
export const NoBytes = Template.bind({});
NoBytes.args = {
backupStep: InstallScreenBackupStep.Download,
currentBytes: undefined,
totalBytes: undefined,
};
export const Bytes = Template.bind({});
Bytes.args = {
backupStep: InstallScreenBackupStep.Download,
currentBytes: 500 * 1024,
totalBytes: 1024 * 1024,
};
export const Full = Template.bind({});
Full.args = {
backupStep: InstallScreenBackupStep.Download,
currentBytes: 1024,
totalBytes: 1024,
};
export const Error = Template.bind({});
Error.args = {
backupStep: InstallScreenBackupStep.Download,
currentBytes: 500 * 1024,
totalBytes: 1024 * 1024,
hasError: true,
};
export const Processing = Template.bind({});
Processing.args = {
backupStep: InstallScreenBackupStep.Process,
currentBytes: 500 * 1024,
totalBytes: 1024 * 1024,
};