diff --git a/jest.setup.js b/jest.setup.js
index 247e095..f5c774c 100644
--- a/jest.setup.js
+++ b/jest.setup.js
@@ -107,11 +107,6 @@ jest.mock('react-native-gesture-handler', () => {
});
-jest.mock('./src/core/helpers/image', () => ({
- loadImage: (url) => url,
- preloadStories: () => [],
-}));
-
jest.mock('./src/core/helpers/storage', () => ({
clearProgressStorage: () => {},
getProgressStorage: jest.fn(),
diff --git a/package-lock.json b/package-lock.json
index 94ed938..5774711 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -24,7 +24,6 @@
"eslint-config-airbnb-typescript": "^16.1.0",
"husky": "^8.0.3",
"jest": "^29.6.2",
- "react-native-blob-util": "^0.19.0",
"react-native-video": "^5.2.1",
"react-test-renderer": "^18.2.0",
"standard-version": "^9.5.0",
@@ -6196,12 +6195,6 @@
"resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz",
"integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw=="
},
- "node_modules/base-64": {
- "version": "0.1.0",
- "resolved": "https://registry.npmjs.org/base-64/-/base-64-0.1.0.tgz",
- "integrity": "sha512-Y5gU45svrR5tI2Vt/X9GPd3L0HNIKzGu202EjxrXMpuc2V2CiKgemAbUUsqYmZJvPtCXoUKjNZwBJzsNScUbXA==",
- "dev": true
- },
"node_modules/base64-js": {
"version": "1.5.1",
"resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz",
@@ -14763,20 +14756,6 @@
"react": "18.2.0"
}
},
- "node_modules/react-native-blob-util": {
- "version": "0.19.0",
- "resolved": "https://registry.npmjs.org/react-native-blob-util/-/react-native-blob-util-0.19.0.tgz",
- "integrity": "sha512-l4HIGDS7Sfio7lq6fQLjTlxDEeOmPiRb8Lj5V9AidGpyrt2ZOWoquXeGjSNncugF3zC+Wq+cIrY8rQtLfRsogA==",
- "dev": true,
- "dependencies": {
- "base-64": "0.1.0",
- "glob": "^7.2.3"
- },
- "peerDependencies": {
- "react": "*",
- "react-native": "*"
- }
- },
"node_modules/react-native-gesture-handler": {
"version": "2.12.1",
"resolved": "https://registry.npmjs.org/react-native-gesture-handler/-/react-native-gesture-handler-2.12.1.tgz",
diff --git a/tests/index.test.js b/tests/index.test.js
index 19bf835..8c5ca7d 100644
--- a/tests/index.test.js
+++ b/tests/index.test.js
@@ -123,13 +123,12 @@ describe( 'Instagram Stories test', () => {
} );
- it( 'Should work with preloadImages & saveProgress', async () => {
+ it( 'Should work with saveProgress', async () => {
jest.spyOn( Storage, 'getProgressStorage' ).mockImplementation( () => ( { 1: '1' } ) );
const { getByTestId, getAllByTestId } = render(
,
);
@@ -170,7 +169,6 @@ describe( 'Instagram Stories test', () => {
const { getByTestId } = render(
,
);
@@ -357,7 +355,7 @@ describe( 'Instagram Stories test', () => {
it( 'Should go to next story', async () => {
- const { getByTestId } = render( );
+ const { getByTestId } = render( );
await act( async () => {
@@ -489,14 +487,10 @@ describe( 'Story Image test', () => {
it( 'Should work with wrong story', () => {
- render( );
+ render( );
} );
-} );
-
-describe( 'Story Image test', () => {
-
it( 'Should work if story already loaded', async () => {
const onLoad = jest.fn();
@@ -506,24 +500,6 @@ describe( 'Story Image test', () => {
active={{ value: true }}
activeStory={{ value: '1' }}
defaultImage="url"
- preloadImages
- onLoad={onLoad}
- /> );
-
- expect( onLoad ).toHaveBeenCalled();
-
- } );
-
- it( 'Should work if story already loaded and preload next image', async () => {
-
- const onLoad = jest.fn();
-
- render( );