-
Notifications
You must be signed in to change notification settings - Fork 14
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
1 parent
d125bc1
commit 860c787
Showing
5 changed files
with
136 additions
and
41 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
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,3 @@ | ||
export default { | ||
"templates/write-canyon-to-local-template.js": "(function () {\n var globalObj = undefined;\n try {\n globalObj = new Function('return this')();\n } catch (e) {\n if (typeof window !== \"undefined\") {\n globalObj = window;\n } else if (typeof global !== \"undefined\") {\n globalObj = global;\n } else {\n // do nothing\n }\n }\n if (globalObj){\n\n // ***start***\n\n if (globalObj.isDocumentAddVisibilitychangeWriteCanyonToLocal) {\n } else {\n globalObj.isDocumentAddVisibilitychangeWriteCanyonToLocal = true\n if (globalObj.document && globalObj.document.addEventListener) {\n if (globalObj.writeCanyonToLocal) {\n globalObj.manualWriteCanyonToLocal = function () {\n globalObj.writeCanyonToLocal(JSON.stringify({\n coverage: globalObj.__coverage__,\n canyon: globalObj.__canyon__\n }))\n }\n }\n globalObj.document.addEventListener('visibilitychange', function () {\n if (globalObj.document.visibilityState === 'hidden') {\n if (globalObj.writeCanyonToLocal) {\n globalObj.writeCanyonToLocal(JSON.stringify({\n coverage: globalObj.__coverage__,\n canyon: globalObj.__canyon__\n }))\n } else {\n console.log('writeCanyonToLocal is not defined')\n }\n }\n });\n }\n }\n\n // **end***\n }\n})()\n" | ||
} |
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 |
---|---|---|
@@ -1,6 +1,23 @@ | ||
module.exports = { | ||
plugins: [ | ||
'istanbul', | ||
'./lib' | ||
['./lib',{ | ||
// 流水线侦测配置 | ||
projectID:'9050', | ||
sha:'xxxxx', | ||
branch:'master', | ||
// 流水线变量里配置 | ||
dsn:'http://localhost:3000', | ||
reporter:'xxxxx', | ||
// 插件里配置 | ||
compareTarget: 'main', | ||
provider: 'tripgl', | ||
// ==========以上是属性============= | ||
// 代理配置 | ||
oneByOne: true, //可配置代理 默认false | ||
special: true, //默认false | ||
keepMap: true, // 默认false | ||
addAttributes:['branch'], //默认全部,有的话用有的,适用于生产 | ||
}] | ||
] | ||
} |