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

[Datumaro] Reducing nesting of tests #1875

Merged
merged 25 commits into from
Jul 20, 2020
Merged

[Datumaro] Reducing nesting of tests #1875

merged 25 commits into from
Jul 20, 2020

Conversation

KochankovID
Copy link
Contributor

@KochankovID KochankovID commented Jul 9, 2020

Motivation and context

Tests are complex. It's necessary to reduce nesting.
To achieve this goal was implemented Dataset.from_iterable(), labelCategories.from_iterable()
and PointsCategories.from_iterable(). The format tests was simplified.

How has this been tested?

It was tested using unittests.

Checklist

License

  • I submit my code changes under the same MIT License that covers the project.
    Feel free to contact the maintainers if that's a concern.
  • I have updated the license header for each file (see an example below)
# Copyright (C) 2020 Intel Corporation
#
# SPDX-License-Identifier: MIT

@coveralls
Copy link

coveralls commented Jul 9, 2020

Pull Request Test Coverage Report for Build 6397

  • 27 of 29 (93.1%) changed or added relevant lines in 2 files are covered.
  • 42 unchanged lines in 4 files lost coverage.
  • Overall coverage decreased (-0.2%) to 65.03%

Changes Missing Coverage Covered Lines Changed/Added Lines %
datumaro/datumaro/components/extractor.py 16 18 88.89%
Files with Coverage Reduction New Missed Lines %
cvat/apps/engine/media_extractors.py 1 77.35%
datumaro/datumaro/components/extractor.py 1 90.96%
datumaro/datumaro/cli/main.py 11 0%
datumaro/datumaro/plugins/voc_format/converter.py 29 88.67%
Totals Coverage Status
Change from base Build 6342: -0.2%
Covered Lines: 11096
Relevant Lines: 16656

💛 - Coveralls

@zhiltsov-max
Copy link
Contributor

Could you fill the PR description?

Copy link
Contributor

@zhiltsov-max zhiltsov-max left a comment

Choose a reason for hiding this comment

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

LGTM, please fix conflicts so it could be merged.

Copy link
Contributor

Codacy Here is an overview of what got changed by this pull request:

Complexity increasing per file
==============================
- datumaro/tests/test_mot_format.py  1
- datumaro/tests/test_coco_format.py  3
         

See the complete overview on Codacy

Copy link
Contributor

@zhiltsov-max zhiltsov-max left a comment

Choose a reason for hiding this comment

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

Looks nice.

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.

4 participants