title: How to solve : "ReferenceError: expect is not defined
body: <p>I'm following <a href="https://egghead.io/lessons/javascript-redux-avoiding-object-mutations-with-object-assign-and-spread" rel="nofollow noreferrer">this egghead tutorial</a> and getting the error in console: </p>
  
  <pre><code>"ReferenceError: expect is not defined
      at testToggleTodo (myproj.js:18:3)
      at myproj.js:25:1
      at https://static.jsbin.com/js/prod/runner-4.0.4.min.js:1:13850
      at https://static.jsbin.com/js/prod/runner-4.0.4.min.js:1:10792"
  </code></pre>
  
  <p><strong>My HTML</strong>:</p>
  
  <pre><code>&lt;!DOCTYPE html&gt;
  &lt;html&gt;
  &lt;head&gt;
    &lt;meta charset="utf-8"&gt;
    &lt;meta name="viewport" content="width=device-width"&gt;
    &lt;title&gt;JS Bin&lt;/title&gt;
  
    &lt;script src="https://wzrd.in/standalone/expect@latest"&gt;&lt;/script&gt;
    &lt;script src="https://wzrd.in/standalone/deep-freeze@latest"&gt;&lt;/script&gt;
  
    &lt;/head&gt;
  &lt;body&gt;
  
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p><strong>ES6/Babel</strong>: </p>
  
  <pre><code>const toggleTodo = (todo) =&gt; {
    todo.completed = !todo.completed;
    return todo;
  };
  
  const testToggleTodo = () =&gt; {
    const todoBefore = {
      id: 0,
      text: 'Learn Redux',
      completed: false
    };
    const todoAfter = {
      id: 0,
      text: 'Learn Redux',
      completed: true
    };
  
    expect(
      toggleTodo(todoBefore)
    ).toEqual(todoAfter);
  };
  
  testToggleTodo();
  console.log('All Tests Passed.');
  </code></pre>
  
  <p>You can see I've imported <code>expect</code> in the <code>head</code> of my HTML: </p>
  
  <p><code>&lt;script src="https://wzrd.in/standalone/expect@latest"&gt;&lt;/script&gt;</code></p>
  
  <p>Why am I still getting the error? What am I missing here?</p>
  
  <p>Thanks.</p>