-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
171 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
--- Global configuration file. Copy, customize and store in your | ||
-- project folder as '.luacov' for project specific configuration. | ||
-- If some options are missing, their default values from this file | ||
-- will be used. | ||
-- @class module | ||
-- @name luacov.defaults | ||
return { | ||
|
||
-- default filename to load for config options if not provided | ||
-- only has effect in 'luacov.defaults.lua' | ||
["configfile"] = ".luacov", | ||
|
||
-- filename to store stats collected | ||
["statsfile"] = "luacov.stats.out", | ||
|
||
-- filename to store report | ||
["reportfile"] = "luacov.report.out", | ||
|
||
-- luacov.stats file updating frequency. | ||
-- The lower this value - the more frequenty results will be written out to luacov.stats | ||
-- You may want to reduce this value for short lived scripts (to for example 2) to avoid losing coverage data. | ||
["savestepsize"] = 100, | ||
|
||
-- Run reporter on completion? (won't work for ticks) | ||
runreport = true, | ||
|
||
-- Delete stats file after reporting? | ||
deletestats = false, | ||
|
||
-- Process Lua code loaded from raw strings | ||
-- (that is, when the 'source' field in the debug info | ||
-- does not start with '@') | ||
codefromstrings = false, | ||
|
||
-- Patterns for files to include when reporting | ||
-- all will be included if nothing is listed | ||
-- (exclude overrules include, do not include | ||
-- the .lua extension, path separator is always '/') | ||
["include"] = {}, | ||
|
||
-- Patterns for files to exclude when reporting | ||
-- all will be included if nothing is listed | ||
-- (exclude overrules include, do not include | ||
-- the .lua extension, path separator is always '/') | ||
["exclude"] = { | ||
"luacov$", | ||
"luacov/reporter$", | ||
"luacov/defaults$", | ||
"luacov/runner$", | ||
"luacov/stats$", | ||
"luacov/tick$", | ||
"lua_install/", | ||
"tests/" | ||
}, | ||
|
||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,81 @@ | ||
--[[-------------------------------------------------------------------------- | ||
The MIT License (MIT) | ||
Copyright (c) 2010-2019 Mark Rogaski | ||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
in the Software without restriction, including without limitation the rights | ||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
copies of the Software, and to permit persons to whom the Software is | ||
furnished to do so, subject to the following conditions: | ||
The above copyright notice and this permission notice shall be included in all | ||
copies or substantial portions of the Software. | ||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
SOFTWARE. | ||
--]]-------------------------------------------------------------------------- | ||
|
||
-- | ||
-- These functions adapt or mock Lua extensions in the WoW API. | ||
-- | ||
require('bit') | ||
|
||
-- Read the TOC file | ||
local TOC = {} | ||
f = io.open('GreenWall.toc') | ||
while true do | ||
line = f:read() | ||
if line == nil then | ||
break | ||
end | ||
k, v = string.match(line, '## (%a+): (.*)%s*$') | ||
if k ~= nil then | ||
TOC[k] = v | ||
end | ||
end | ||
f:close() | ||
|
||
function date(...) | ||
return os.date(...) | ||
end | ||
|
||
function strmatch(...) | ||
return string.match(...) | ||
end | ||
|
||
function GetAddOnMetadata(addon, field) | ||
if addon == TOC['Title'] then | ||
return TOC['Version'] | ||
end | ||
return | ||
end | ||
|
||
function GetRealmName() | ||
return 'EarthenRing' | ||
end | ||
|
||
function UnitName(target) | ||
if target == 'player' then | ||
return 'Ralff' | ||
end | ||
return | ||
end | ||
|
||
function GetBuildInfo() | ||
x, y, z = string.match(TOC['Interface'], '(%d)(%d%d)(%d%d)') | ||
version = string.format('%d.%d.%d', x, y, z) | ||
return version, '12345', os.date(), TOC['Interface'] | ||
end | ||
|
||
function hooksecurefunc(...) | ||
return | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters