docs: function(results) {
  
              var currentTestNum = 1;
  
              function serializeToTAP(results){
                  var text = "";
  
                  switch (results.type){
  
                      case "test":
                          if (results.result != "ignore"){
  
                              text = "ok " + (currentTestNum++) + " - " + results.name;
  
                              if (results.result == "fail"){
                                  text = "not " + text + " - " + results.message;
                              }
  
                              text += "\n";
                          } else {
                              text = "#Ignored test " + results.name + "\n";
                          }
                          break;
  
                      case "testcase":
  
                          text = "#Begin testcase " + results.name + "(" + results.failed + " failed of " + results.total + ")\n";
  
                          for (var prop in results){
                              if (results.hasOwnProperty(prop)){
                                  if (results[prop] && typeof results[prop] == "object" && !(results[prop] instanceof Array)){
                                      text += serializeToTAP(results[prop]);
                                  }
                              }
                          }
  
                          text += "#End testcase " + results.name + "\n";
  
  
                          break;
  
                      case "testsuite":
  
                          text = "#Begin testsuite " + results.name + "(" + results.failed + " failed of " + results.total + ")\n";
  
                          for (var prop in results){
                              if (results.hasOwnProperty(prop)){
                                  if (results[prop] && typeof results[prop] == "object" && !(results[prop] instanceof Array)){
                                      text += serializeToTAP(results[prop]);
                                  }
                              }
                          }
  
                          text += "#End testsuite " + results.name + "\n";
                          break;
  
                      case "report":
  
                          for (var prop in results){
                              if (results.hasOwnProperty(prop)){
                                  if (results[prop] && typeof results[prop] == "object" && !(results[prop] instanceof Array)){
                                      text += serializeToTAP(results[prop]);
                                  }
                              }
                          }
  
                      //no default
                  }
  
                  return text;
  
              }
  
              return "1.." + results.total + "\n" + serializeToTAP(results);
          }