Microsoft
70-354 · Question #42
You are developing a Universal Windows Platform (UWP) app that has the following unit test. ``csharp { public class UnitTest1 { { [TestMethod] public void TestMethod1() { } } } } `` You need to…
The correct answer is D. [TestClass] before the UnitTest1 declaration. See the full explanation below for the reasoning.
Question
You are developing a Universal Windows Platform (UWP) app that has the following unit test.
{
public class UnitTest1
{
{
[TestMethod]
public void TestMethod1()
{
}
}
}
}
You need to ensure that TestMethod1 appears in the Test Explorer window of Microsoft Visual Studio. What should you add?Options
- A[TestProperty("AutoStart","True")] before the TestMethod1 declaration
- B[TestCategory("Enabled")] before the UnitTest1 declaration
- C[TestProperty("Enabled", "True")] before the TestMethod1 declaration
- D[TestClass] before the UnitTest1 declaration
How the community answered
(70 responses)- A3% (2)
- B13% (9)
- C6% (4)
- D79% (55)
Community Discussion
No community discussion yet for this question.