intra2net / guibot

A tool for GUI automation using a variety of computer vision and display control backends.
http://guibot.org
GNU Lesser General Public License v3.0
171 stars 21 forks source link

Introduce the new `fileresolver` module #15

Closed samiraguiar closed 4 years ago

samiraguiar commented 4 years ago

Originally called imagefinder, the path module was renamed to imagepath as imagefinder started referring to the module responsible for using computer vision to locate images on a region. Later the "image" prefix was dropped as the modules had become more generalized, supporting other targets beyond simple images.

As a result of these renames, the name of the module stopped conveying the correct meaning as the term "path" is too broad. Unlike location and target it doesn't represent a path, and although it performs an action, it doesn't end with er as imagelogger and finder.

This PR renames it one more time — now to fileresolver — in accordance with other similar modules. The legacy path module was kept for compatibility reasons, but is now deprecated and will be removed in later versions.

A secondary class, called CustomFileResolver, is also added to allow users to define a temporary list of paths to be used to resolve files.

codecov[bot] commented 4 years ago

Codecov Report

Merging #15 into master will increase coverage by 0.04%. The diff coverage is 91.35%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master      #15      +/-   ##
==========================================
+ Coverage   65.44%   65.48%   +0.04%     
==========================================
  Files          15       16       +1     
  Lines        4410     4433      +23     
==========================================
+ Hits         2886     2903      +17     
- Misses       1524     1530       +6     
Impacted Files Coverage Δ
guibot/guibot.py 0.00% <0.00%> (ø)
guibot/target.py 84.29% <88.88%> (ø)
guibot/fileresolver.py 96.82% <96.82%> (ø)
guibot/finder.py 56.60% <100.00%> (-0.17%) :arrow_down:
guibot/path.py 100.00% <100.00%> (+4.54%) :arrow_up:
guibot/calibrator.py 75.71% <0.00%> (-1.08%) :arrow_down:

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 8ad72bb...21d1fdc. Read the comment docs.

lgtm-com[bot] commented 4 years ago

This pull request introduces 2 alerts and fixes 1 when merging a649d6dee5f6887dbc0bc30ad98ca2d2abd0b44b into 8ad72bb1cadd60b1ec61fd5115329d9dcfee2061 - view on LGTM.com

new alerts:

fixed alerts:

lgtm-com[bot] commented 4 years ago

This pull request fixes 1 alert when merging 8da5a6d96609c3c2a3d69e0c474be70ea6ff148d into 8ad72bb1cadd60b1ec61fd5115329d9dcfee2061 - view on LGTM.com

fixed alerts:

lgtm-com[bot] commented 4 years ago

This pull request fixes 1 alert when merging 21d1fdcb9e109619df40851f153ecae01425ac75 into 8ad72bb1cadd60b1ec61fd5115329d9dcfee2061 - view on LGTM.com

fixed alerts: