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

Fixed Lab Module + Tests #162

Merged
merged 4 commits into from
May 16, 2024
Merged

Fixed Lab Module + Tests #162

merged 4 commits into from
May 16, 2024

Conversation

nij-patel
Copy link
Member

Changes

updated lab.py:

  • Use the new lab API (old one lead to nothing), and now Pitt uses an interactive map to show lab statuses. Found the new one by examining network traffic.
  • New API (and all other ones on the site) don't return numbers for Mac/Windows/Linux available, so I removed those.
  • _fetch_labs() now return dictionary of labs and if they are open or not
  • get_status() returns more detailed info about the labs, like how many total machines + how many open

updated lab_test.py:

  • old mock data is no longer relevant, so updated/trimmed to two tests
  • assert instance of return

Testing

  • tested the methods locally and then the tests. all pass locally!

@nij-patel nij-patel self-assigned this May 16, 2024
@nij-patel nij-patel linked an issue May 16, 2024 that may be closed by this pull request
@nij-patel nij-patel merged commit 47d2a54 into dev May 16, 2024
1 check failed
Copy link
Contributor

Choose a reason for hiding this comment

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

@nij-patel Did you mean to commit this coverage file?

@tianyizheng02
Copy link
Contributor

Also, is it safe to delete your 154-labs-dev branch?

@nij-patel nij-patel deleted the 154-labs-dev branch May 22, 2024 15:51
tianyizheng02 added a commit that referenced this pull request May 22, 2024
Delete the coverage file `.coverage 2`, which was introduced in #162. Coverage files are supposed to be excluded according to the .gitignore.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

fix failing tests for lab
2 participants