1
我試圖分配組TestNG的類和方法在斯卡拉環境(在Eclipse)指定TestNG的測試組在斯卡拉
@Test(groups="register")
class RegisterTest {
...
,但我遇到了以下錯誤:
Multiple markers at this line
- type mismatch; found : java.lang.String("register") required:
Array[java.lang.String]
- annotation argument needs to be a constant; found: "register"{<error>}
我已經嘗試將組應用到單獨的Scala方法,但仍然遇到相同的錯誤。
有關如何解決此問題的任何建議?
只要沒有指定任何參數(如果指定dependsOnMethods
參數,則出現同樣的錯誤),@Test
註釋將起作用。
@DataProvider
註釋也適用。
而且獎品是...奶酪片。謝謝 – 2012-07-26 20:16:23