Skip to content
This repository has been archived by the owner on Aug 2, 2023. It is now read-only.

Add unhandled exception tests #682

Merged
merged 16 commits into from
Jul 23, 2018
Merged

Conversation

karthiknadig
Copy link
Member

@karthiknadig karthiknadig commented Jul 19, 2018

This PR does the following:

@codecov-io
Copy link

codecov-io commented Jul 19, 2018

Codecov Report

Merging #682 into master will increase coverage by 0.01%.
The diff coverage is 50%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #682      +/-   ##
==========================================
+ Coverage   60.18%   60.19%   +0.01%     
==========================================
  Files          27       27              
  Lines        3823     3824       +1     
==========================================
+ Hits         2301     2302       +1     
  Misses       1522     1522
Impacted Files Coverage Δ
ptvsd/wrapper.py 52.78% <50%> (+0.03%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 501d163...84b4299. Read the comment docs.

@karthiknadig
Copy link
Member Author

@DonJayamanne I am running into timeouts on VSTS for windows for some of the tests. Not sure if this is because the timeout is too short for those tests. This does not repro when running locally.

@karthiknadig karthiknadig changed the title [WIP] - Do not review - Add unhandled exception tests [WIP] Add unhandled exception tests Jul 19, 2018
@@ -258,22 +258,28 @@ def test_breaking_into_handled_exceptions(self):
DebugInfo(filename=filename, cwd=cwd))

def test_breaking_into_uncaught_exceptions(self):
DebugSessionConnection.VERBOSE = True
filename = TEST_FILES.resolve('unhandled_exceptions_launch.py')
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is something that should be done with a context manager (with)

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I won’t be using that. I added that temporarily to find a issue I was running into on Travis.

@karthiknadig karthiknadig reopened this Jul 20, 2018
@karthiknadig karthiknadig reopened this Jul 20, 2018
@karthiknadig karthiknadig reopened this Jul 20, 2018
@karthiknadig karthiknadig changed the title [WIP] Add unhandled exception tests Add unhandled exception tests Jul 20, 2018
@karthiknadig
Copy link
Member Author

@DonJayamanne This is ready for review.

ptvsd/wrapper.py Outdated
@@ -798,7 +799,7 @@ def _parse_debug_options(opts):
continue

if 'CLIENT_OS_TYPE' not in options:
options['CLIENT_OS_TYPE'] = 'WINDOWS' if platform.system() == 'Windows' else 'UNIX' # noqa
options['CLIENT_OS_TYPE'] = 'WINDOWS' if platform.system() == 'Windows' else 'UNIX' # noqa
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Linter issue, you need only one space before #

'breakMode': 'unhandled',
'details': {
'typeName': 'ValueError',
# 'source': debug_info.filename
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please enable testing of source

'breakMode': 'always',
'details': {
'typeName': 'ValueError',
# 'source': debug_info.filename
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please enable testing of source

'breakMode': 'always',
'details': {
'typeName': 'ValueError',
# 'source': debug_info.filename
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please enable testing of source

@karthiknadig karthiknadig reopened this Jul 23, 2018
@karthiknadig karthiknadig merged commit 5db5b30 into microsoft:master Jul 23, 2018
@karthiknadig karthiknadig deleted the issue654 branch August 8, 2018 00:36
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants