pcdshub / pytmc

Generate EPICS IOCs and records from TwinCAT projects - along with many TwinCAT project tools
https://pcdshub.github.io/pytmc/
Other
10 stars 11 forks source link

Pinned Global Variables have different <Name> field #144

Closed n-wbrown closed 4 years ago

n-wbrown commented 4 years ago

This PR alters the 'pragmas.get_pragma' method to identify pragmas based upon a list of acceptable strings instead of matching against a single string. Default arguments have been updated to match.

codecov-io commented 4 years ago

Codecov Report

Merging #144 into master will increase coverage by 0.28%. The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #144      +/-   ##
==========================================
+ Coverage   77.78%   78.06%   +0.28%     
==========================================
  Files          17       17              
  Lines        1904     1906       +2     
==========================================
+ Hits         1481     1488       +7     
+ Misses        423      418       -5
Impacted Files Coverage Δ
pytmc/pragmas.py 95.04% <100%> (+0.08%) :arrow_up:
pytmc/parser.py 87.8% <0%> (+0.55%) :arrow_up:
pytmc/bin/stcmd.py 86.99% <0%> (+1.62%) :arrow_up:

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 ee7cd05...881d3a0. Read the comment docs.

n-wbrown commented 4 years ago

@slacAWallace pmps-dev-arbiter contains pinned global variables but none of them are instantiated in pytmc. Their top level GVL does not contain a pragma so no pinned global variables are created. To accommodate, I've incorporated the .tmc file sent to us on the 26th which does include fully instantiated pragmas for testing pytmc's ability to identify and render pinned global variables. What project this .tmc file come from?

The pmps-dev-arbiter test is currently marked for xfail.

n-wbrown commented 4 years ago

closes #140