(jest as any).disableAutomock();

import middleware from '../server';

describe('retax server', () => {
  const serverConfig = {
    serverRendering: true,
  };

  it('exposes the middleware', () => {
    expect(middleware instanceof Function).toBeTruthy();
    expect(middleware(serverConfig) instanceof Function);
  });
});

(jest as any).disableAutomock();

import middleware from '../server';

describe('retax server', () => {
  it('exposes the middleware', () => {
    expect(middleware instanceof Function).toBeTruthy();
  });
});

--- 
+++ 
@@ -3,7 +3,12 @@
 import middleware from '../server';
 
 describe('retax server', () => {
+  const serverConfig = {
+    serverRendering: true,
+  };
+
   it('exposes the middleware', () => {
     expect(middleware instanceof Function).toBeTruthy();
+    expect(middleware(serverConfig) instanceof Function);
   });
 });
Increase the coverage to 100%.

Just to have a green badge! These tests for 'retax' are not really revelant. All sub retax modules are already tested.
