在 Flex Builder 中使用 AsUnit 对库进行单元测试

发布于 2024-08-23 14:01:42 字数 346 浏览 3 评论 0原文

我一直在尝试使用 Flex Builder 设置一种用于单元测试 Flex 库的工作方法。

我尝试设置一个标准的 Flex lib 项目并使用 Ant 编译和运行单元测试。但这意味着当出现问题并且我想使用 Flex 构建器调试器时我无法这样做。

所以我的下一个计划是将库设置为普通的 as3/flax/air 应用程序,因为我可以使用主类的概念来运行单元测试。然后我可以使用 Ant 编译实际的库代码。

我还可以设置一个单独的配套项目,其唯一任务是在库上运行单元测试。但这有点尴尬,因为每个库现在都需要管理两个项目。

这一切对我来说似乎有点混乱。 其他人如何开发 Flex 库并使用单元测试来测试/开发/调试代码?

I've been trying to setup a working method for unit testing flex libraries using Flex Builder.

I have tried setting up a standard flex lib project and using Ant to compile and run the units tests. But this means that when something does go wrong and I want to use the flex builder debugger I cannot do so.

So my next plan is to setup the library as a normal as3/flax/air app as I can use the concept of a main class to run the unit tests. I can then compile the actual library code using Ant.

I could also setup a separate companion project who's sole task is to run units tests on the lib. But this is a little awkward as each library now requires two projects to manage.

This all seems a little messy to me.
How do other people develop flex libraries and use unit tests to test/develop/debug the code?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

大姐,你呐 2024-08-30 14:01:42

你用什么版本?使用 FlexBuilder 进行单元测试并不是很好(轻描淡写!)。

如果有机会,请尝试 FlashBuilder,它工作得更好,而且新的 FlexUnit4 测试与 CI 的集成比旧的测试要好得多。

What version do you use? Unit testing with FlexBuilder ist not very nice (understatement!).

If you have the opportunity, try FlashBuilder, it works much nicer and the new FlexUnit4 tests do integrate much better with CI than the old ones.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文