简体   繁体   English

Chutzpah未检测到包含枚举的TypeScript测试

[英]Chutzpah not detecting TypeScript tests which contain enums

I am trying to use Visual Studio 2012, Chutzpah and QUnit for unit testing on a TypeScript project and have encountered a problem. 我正在尝试使用Visual Studio 2012,Chutzpah和QUnit对TypeScript项目进行单元测试,但遇到了问题。

Chutzpah successfully detects the following code and lists the test in the Test Explorer: Chutzpah成功检测到以下代码,并在“测试资源管理器”中列出了测试:

/// <reference path="../../modules/qunit.d.ts" />
test("A Test", () => { });

However, if I reference any TypeScript which makes use of an enum, no test is detected. 但是,如果我引用任何使用枚举的TypeScript,则不会检测到测试。

For example: 例如:

/// <reference path="../../modules/qunit.d.ts" />
module A {
    export enum B { };
    export var C: B;
}

test("A Test", () => { });

I am using: 我在用:

  • VS2012 Update 4 VS2012更新4
  • Chutzpah 3.0.0 丘兹帕3.0.0
  • Typescript 0.9.5 打字稿0.9.5
  • QUnit 1.12.0 QUnit 1.12.0

Is this a bug with Chutzpah Typescript support for enums? 这是Chutzpah Typescript对枚举的支持的错误吗?

This was a bug in version 3.0.0. 这是3.0.0版中的错误。 It is now fixed in the 3.0.1 release. 现在,此问题已在3.0.1版本中修复。 If you upgrade this should work. 如果升级,这应该可以工作。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM