instead of ignoring dot tests, add them as pending

This commit is contained in:
Sebastian McKenzie
2014-11-15 02:49:28 +11:00
parent 47c6f74251
commit 682806f1ca
3 changed files with 3 additions and 4 deletions

View File

@@ -36,8 +36,6 @@ exports.get = function (entryName) {
if (fs.existsSync(suiteOptsLoc)) suite.options = require(suiteOptsLoc);
_.each(fs.readdirSync(suite.filename), function (taskName) {
if (taskName[0] === ".") return;
var taskDir = suite.filename + "/" + taskName;
if (fs.statSync(taskDir).isFile()) return;
@@ -59,6 +57,7 @@ exports.get = function (entryName) {
var test = {
title: humanise(taskName),
disabled: taskName[0] === ".",
options: taskOpts,
exec: {
code: readFile(execLoc),

View File

@@ -22,7 +22,7 @@ suite("generation", function () {
_.each(helper.get("generation"), function (testSuite) {
suite("generation/" + testSuite.title, function () {
_.each(testSuite.tests, function (task) {
test(task.title, function () {
test(task.title, !task.disabled && function () {
var expect = task.expect;
var actual = task.actual;

View File

@@ -64,7 +64,7 @@ var run = function (task) {
_.each(helper.get("transformation"), function (testSuite) {
suite("transformation/" + testSuite.title, function () {
_.each(testSuite.tests, function (task) {
test(task.title, function () {
test(task.title, !task.disabled && function () {
var runTask = function () {
run(task);
};