title: How to fabricate a turnContext for testing Microsoft Botbuilder SDK?
body: <p>IDE: Visual Studio 2017
  SDK: Botbuilder V4
  Emulator: Bot-Framework Emulator V4
  Language: Node.js v11</p>
  
  <p>Hi all. I am making test cases for some largely static functions/methods of my bot code. However, I will later need to test more advanced functionality of my bot to test for specific behavior. Does anyone know how to fabricate some parts of the turnContext?</p>
  
  <p>For example, I am fabricating my own right now by manually creating a simulated turnContext JSON in the following way:</p>
  
  <pre><code>turnContext {
  activity: {
      text: "custom test text",
      channelID: "custom ID",
      conversation: {
          id: "custom ID" } } }
  </code></pre>
  
  <p>The problem is that this fabricated context doesn't actually have the inhereted methods like <code>turnContext.sendActivity('custom message');</code>. So my tests will be limited to only the most basic functionality of the bot that won't actually guarantee the entire behavior is performing as designed.</p>