Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test_system_nidmm.py test_ViSession_attribute fails #95

Closed
marcoskirsch opened this issue Jul 27, 2017 · 1 comment
Closed

test_system_nidmm.py test_ViSession_attribute fails #95

marcoskirsch opened this issue Jul 27, 2017 · 1 comment

Comments

@marcoskirsch
Copy link
Member

Test expects session.io_session = 5 to raise TypeError.
This test used to work, although someone could argue that we should allow setting a numeric value on a ViSession.

__________________________ test_ViSession_attribute ___________________________

device_info = {'name': '4070', 'sn': '00D82BA5'}

    def test_ViSession_attribute(device_info):
        with nidmm.Session(device_info['name']) as session:
            try:
                session.io_session = 5
>               assert False
E               assert False

src\nidmm\system_tests\test_system_nidmm.py:108: AssertionError
@marcoskirsch
Copy link
Member Author

The reason this now fails is that the io_session went away from metadata. So the line:

session.io_session = 5

is inserting a new attribute into the session instance.

So the test is invalid and I will fix it. But it raises the question of whether we should disallow inserting attributes into the session instance.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant