Code-coverage - AS3 Classes: Error

ASSIGNED
Unassigned

Status

Tamarin
Tools
P4
normal
ASSIGNED
8 years ago
7 years ago

People

(Reporter: Chris Peyer, Unassigned)

Tracking

(Blocks: 1 bug)

unspecified
Q2 12 - Cyril
Bug Flags:
flashplayer-qrb +
flashplayer-bug -

Details

(Whiteboard: code-coverage, loose-end)

Attachments

(1 attachment)

(Reporter)

Description

8 years ago
as of redux r5139:

                        covered      total        covered    total      
class                 functions  functions   pct     cond     cond   pct
Error                         9         16  56.2        3        6  50.0

coverage of:

avmplus::ErrorClass::
avmplus::ErrorObject::
Flags: flashplayer-qrb?
(Reporter)

Updated

8 years ago
Whiteboard: code-coverage

Updated

8 years ago
Assignee: nobody → brbaker
Status: NEW → ASSIGNED
Flags: flashplayer-qrb? → flashplayer-qrb+
Priority: -- → P3
Target Milestone: --- → flash10.2.x-Spicy

Comment 1

8 years ago
Created attachment 484324 [details] [diff] [review]
Additional coverage for Error

Coverage data generated running the following acceptance runs with a release-debugger build of the shell.

Acceptance Runs:
./runtests.py as3/Statements/Exceptions as3/RuntimeErrors as3/ErrorObject ecma3/Exceptions ecma3/ErrorObject 
./runtests.py --vmargs=-Dnodebugger as3/Statements/Exceptions as3/RuntimeErrors as3/ErrorObject ecma3/Exceptions ecma3/ErrorObject 

Coverage classes: (covselect -l)
exclude all /
exclude folder ../../../tamarin-redux/
include source ../../../tamarin-redux/core/ErrorClass.cpp
include source ../../../tamarin-redux/core/ErrorClass.h

Coverage Results: (covclass -m)
Class                            Function Coverage           C/D Coverage
---------------------------  ---------------------  ---------------------
avmplus::                        11 /    11 = 100%       5 /     6 =  83%
avmplus::ErrorClass::             5 /     5 = 100%       0 /     0       
avmplus::ErrorObject::            4 /     4 = 100%       5 /     6 =  83%
avmplus::NativeErrorClass::       2 /     2 = 100%       0 /     0       
---------------------------  ---------------------  ---------------------
Total                            11 /    11 = 100%       5 /     6 =  83%

Additional testcase is simply to cover getStackTrace() within a known testcase. This is currently covered elsewhere in the suite, but this makes coverage easier to reproduce.

Add an acceptance pass in code coverage to pick up code paths available when debugger is compiled in BUT not enabled (via -Dnodebugger)
Attachment #484324 - Flags: review?(dschaffe)

Comment 2

8 years ago
Comment on attachment 484324 [details] [diff] [review]
Additional coverage for Error

- what does -Dnodebugger add to code coverage?
- I would have made the test smaller by just included the try/catch finally part of the test and not used getTestCases since there is only 1 test. but that is just me.
Attachment #484324 - Flags: review?(dschaffe) → review+

Comment 3

8 years ago
(In reply to comment #2)
> Comment on attachment 484324 [details] [diff] [review]
> Additional coverage for Error
> 
> - what does -Dnodebugger add to code coverage?

There are branches in the VM that check to see if a debugger is attached and they will only be compiled in if the build is debugger. So the -Dnodebugger gives the 'true' coverage of the following:
       63         #ifdef DEBUGGER
       64         AvmCore *core = this->core();
       65         if (!core->debugger())
       66             return;

Updated

8 years ago
Target Milestone: flash10.2.x-Spicy → flash10.x - Serrano

Comment 4

8 years ago
Comment on attachment 484324 [details] [diff] [review]
Additional coverage for Error

Patch pushed as 5373:fde08035a073

Comment 5

7 years ago
can close?

Updated

7 years ago
Target Milestone: Q3 11 - Serrano → Q4 11 - Anza

Comment 6

7 years ago
Brent, can this be closed?
Flags: flashplayer-bug-
Whiteboard: code-coverage → code-coverage, loose-end
Target Milestone: Q4 11 - Anza → Q1 12 - Brannan

Updated

7 years ago
Priority: P3 → P4

Updated

7 years ago
Assignee: brbaker → nobody
Target Milestone: Q1 12 - Brannan → Q2 12 - Cyril
You need to log in before you can comment on or make changes to this bug.