How to unit test an angular 2 component when I don't care about the dependencies? I just want to test some inner functions
<p>I'm new to writing unit tests, and unfortunately I've already built a few "complicated" (for me) components which I am having a hard time even beginning to write tests for.</p>

<p>Here's a snippet of my code, including the constructor.  Basically, I don't really care right now about these dependencies, I want to test some inner functions such as resizing based on array size, etc.  For these, I can just create an Array.fill and should be good to go.</p>

<pre><code>export class GalleryComponent implements OnInit {

  photos = [];

  galleryState: Observable&lt;any&gt;;

  constructor(
    private store: Store&lt;any&gt;,
    private photoActions: PhotoActions,
    private router: Router
  ) {
    this.galleryState = this.store.select&lt;any&gt;(state =&gt; state.photos.gallery);
  }
}
</code></pre>

<p>In my other components which have nothing in the constructor, instantiating the component in my test is as simple as <code>new SomeComponent()</code>.</p>

<p>However, in the <code>GalleryComponent</code> above, I am wondering if there is a way that I can literally ignore the dependencies completely (for now), and instead just instantiate the component in a way that I can test some inner functions easily.  For example, say I had the following function inside GalleryComponent:</p>

<pre><code>function timesByTwo(number) {
  return number * 2;
}
</code></pre>

<p>This is not at all related to any of the dependencies, so how can I just test that one function given that this component has 3 dependencies?</p>

<p>Thanks</p>