title: How do I write unit tests for a single JS file?
body: <p>I have a single js file with a function in in. I want to write unit tests for the function and deliver the tests and file to someone. It needs to be standalone.</p>
  
  <p>Here is my project:</p>
  
  <pre><code>src: myFunction.js
  tests: empty for now
  </code></pre>
  
  <p>myFunction.js:</p>
  
  <pre><code>function HelloWord() {
     return 'Hello';
  }
  </code></pre>
  
  <p>It would be great to have a test file like this:</p>
  
  <pre><code>import { func } from './myFunction.js';
  
  describe('tests', function () {
      it('returns hello', function () {
          expect(func()).toEqual('Hello');
      });
  });
  </code></pre>
  
  <p>I don't know which unit test framework would be the easiest and fastest to accomplish what I need to do. The user needs to get my directory and just run the tests from the command line.</p>