# Karma and Webpack: Module not found: Error: Can't resolve './assets/images/phone.svg'

**URL:** <https://forum.ionicframework.com/t/karma-and-webpack-module-not-found-error-cant-resolve-assets-images-phone-svg/87558>\
**Category:** ionic-v3\
**Created:** [April 23, 2017, 9:33pm UTC](https://forum.ionicframework.com/t/karma-and-webpack-module-not-found-error-cant-resolve-assets-images-phone-svg/87558 "2017-04-23T21:33:24Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![anon70733690](https://avatars.discourse-cdn.com/v4/letter/a/2acd7d/32.png) [@anon70733690](https://forum.ionicframework.com/u/anon70733690)\
**Post date:** [April 23, 2017, 9:33pm UTC](https://forum.ionicframework.com/t/karma-and-webpack-module-not-found-error-cant-resolve-assets-images-phone-svg/87558/1 "2017-04-23T21:33:24Z")

</div>

I am having an extremely hard time to get Unit Testing with Karma, Webpack and Ionic 3 to run. After moving through error after error related to Webpack I am now at this:

```auto

ERROR in ./src/+onboarding/onboarding-details/onboarding-details.component.html
Module not found: Error: Can't resolve './assets/images/phone.svg' in '/Users/tyrion/devel/saveup-mobile-front/src/+onboarding/onboarding-details'

```

I tried resolve extensions and module loaders in my **webpack.test.js:**

```auto
    module: {
        rules: [
             {
                 test: /\.(png|jpg|svg)$/,
                 loader: 'url-loader?limit=8192'
            },

```

```auto
    resolve: {
        extensions: ['.ts', '.js','.png','.svg']
    },

```

Tried:

```auto
npm install null-loader file-loader

```

No success. Please help.

---

<div class="post-metadata">

**Author:** ![Lica](https://avatars.discourse-cdn.com/v4/letter/l/48db29/32.png) [@Lica](https://forum.ionicframework.com/u/Lica)\
**Post date:** [May 17, 2017, 10:02pm UTC](https://forum.ionicframework.com/t/karma-and-webpack-module-not-found-error-cant-resolve-assets-images-phone-svg/87558/2 "2017-05-17T22:02:26Z")

</div>

I had the same issue. This tutorial helped me to set up the testing infrastructure correctly:  
[http://lathonez.com/2017/ionic-2-unit-testing/](http://lathonez.com/2017/ionic-2-unit-testing/)
