/*global describe, it*/
/*
 * mochify.js
 *
 * Copyright (c) 2014 Maximilian Antoni <mail@maxantoni.de>
 *
 * @license MIT
 */
'use strict';

var assert = require('assert');
var run    = require('./fixture/run');


describe('stack', function () {
  this.timeout(3000);

  it('does not screw up xunit', function (done) {
    run('passes', ['-R', 'xunit'], function (code, stdout) {
      var lines = stdout.split('\n');
      assert.equal(lines[1].substring(0, lines[1].length - 3),
          '<testcase classname="test" name="passes" time="0');
      assert.equal(lines[2], '</testsuite>');
      assert.equal(code, 0);
      done();
    });
  });

});

@@ -422,125 +422,136 @@
     
-assert.equal(lines%5B1%5D.substring(0, lines%5B1%5D.length - 3),%0A          '%3Ctestcase classname=%22test%22 name=%22passes%22 time=%220'
+var expect = '%3Ctestcase classname=%22test%22 name=%22passes%22 time=%220';%0A      assert.equal(lines%5B1%5D.substring(0, expect.length), expect
 );%0A 

Fix test case to not fail due to varying timing (again)