title: Jest mock the window.open
body: <p>How I can mock the window.open with jest?
  I tried several options but each of them is failed</p>
  
  <p>I need to check if the window.open is called and it should be called with certain params</p>
  
  <p>Assume that I have something like this</p>
  
  <pre><code>open(): void {
    window.open('/link');
  }
  </code></pre>