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

Check meta refresh tags #24

Merged
merged 2 commits into from
Nov 24, 2016
Merged

Check meta refresh tags #24

merged 2 commits into from
Nov 24, 2016

Conversation

wjdp
Copy link
Owner

@wjdp wjdp commented Nov 24, 2016

Add meta tags to NodesOfInterest.
Split generic ref checking from checkGeneric, make hT.checkGenericRef function.

Create check-meta.go, hT.checkMeta function. This checks meta tags.

Forward meta tags to this function when scanning through NodesOfInterest.

If a meta tag has http-equiv == "refresh" we check several things now:

  • Is the content attr present and non-blank
  • Is the first term in the content attr a positive integer
  • Is the separator ;url=
  • Is what follows ;url= a valid reference

Add options CheckMeta, CheckGeneric and CheckMetaRefresh.

Will close #20 and sets us up for opengraph checks, re #7.

Split generic ref checking from checkGeneric, make hT.checkGenericRef
function.

Create check-meta.go, hT.checkMeta function. This checks meta tags.

Forward meta tags to this function when scanning through
NodesOfInterest.

If a meta tag has http-equiv == "refresh" we check several things now:
- Is the content attr present and non-blank
- Is the first term in the content attr a positive integer
- Is the separator ;url=
- Is what follows ;url= a valid reference
Adds options CheckMeta, CheckGeneric and CheckMetaRefresh.
@codecov-io
Copy link

Current coverage is 94.47% (diff: 100%)

Merging #24 into master will increase coverage by 0.33%

@@             master        #24   diff @@
==========================================
  Files            15         16     +1   
  Lines           786        833    +47   
  Methods           0          0          
  Messages          0          0          
  Branches          0          0          
==========================================
+ Hits            740        787    +47   
  Misses           33         33          
  Partials         13         13          

Powered by Codecov. Last update e4758ec...37034ad

@wjdp
Copy link
Owner Author

wjdp commented Nov 24, 2016

Travis OSX builds are broken currently, ignore

@wjdp wjdp merged commit 5295950 into master Nov 24, 2016
@wjdp wjdp deleted the meta-refresh branch November 24, 2016 01:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Check meta refresh locations
2 participants