Forum member
Noctis
3 posts
Posts by Noctis
-
Constants are not covered/tested even though there are tests for them?
[quote=Remco;3567]Hi, thanks for posting! NCrunch won't show markers next to constants, as they aren't represented in the debug information for an assembly. Constants are handled very differently by the compiler (vs normal source code). You'll notice that it isn't possible to set a breakpoint o…
22 Jan 2013 23:20 UTC
-
Constants are not covered/tested even though there are tests for them?
Err ... this is bizzare ... So, I changed my code back (in our example: foo ="bar"; where it used to be foo="trolled"), and was about to go on with my work ... Now my Nunit tests are all green and happy ... but ... now Ncrunch is showing me a red bar ... and complaining that check_const fails b…
22 Jan 2013 00:41 UTC
-
Constants are not covered/tested even though there are tests for them?
Have a class A, and a Test for it: ------------------------------- [code=csharp]class A() { public const string foo = "bar"; public int int_prop{ get { return 7; }} } [Test] public void check_const() { A a = new A(); Assert.AreEqual(a.foo, "bar"); } [/code] --------------…
22 Jan 2013 00:33 UTC