-
Notifications
You must be signed in to change notification settings - Fork 10.6k
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
12 changed files
with
185 additions
and
2 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,5 @@ | ||
--- | ||
"@rocket.chat/meteor": patch | ||
--- | ||
|
||
fix: Discussion messages deleted despite the "Do not delete discussion messages" retention policy enabled |
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
1 change: 1 addition & 0 deletions
1
apps/meteor/packages/rocketchat-coverage/.npm/package/.gitignore
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 @@ | ||
node_modules |
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,7 @@ | ||
This directory and the files immediately inside it are automatically generated | ||
when you change this package's NPM dependencies. Commit the files in this | ||
directory (npm-shrinkwrap.json, .gitignore, and this README) to source control | ||
so that others run the same versions of sub-dependencies. | ||
|
||
You should NOT check in the node_modules directory that Meteor automatically | ||
creates; if you are using git, the .gitignore file tells git to ignore it. |
52 changes: 52 additions & 0 deletions
52
apps/meteor/packages/rocketchat-coverage/.npm/package/npm-shrinkwrap.json
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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,18 @@ | ||
Package.describe({ | ||
name: 'rocketchat:coverage', | ||
summary: '', | ||
version: '1.0.0', | ||
}); | ||
|
||
Package.onUse(function (api) { | ||
api.use('ecmascript'); | ||
api.use('isobuild:compiler-plugin@1.0.0'); | ||
|
||
api.mainModule('plugin/compile-version.js', 'server'); | ||
}); | ||
|
||
Npm.depends({ | ||
'istanbul-lib-report': '3.0.0', | ||
'istanbul-reports': '3.0.2', | ||
'istanbul-lib-coverage': '3.0.0', | ||
}); |
54 changes: 54 additions & 0 deletions
54
apps/meteor/packages/rocketchat-coverage/plugin/compile-version.js
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,54 @@ | ||
import { exec } from 'child_process'; | ||
import os from 'os'; | ||
import util from 'util'; | ||
|
||
import libReport from 'istanbul-lib-report'; | ||
import reports from 'istanbul-reports'; | ||
import libCoverage from 'istanbul-lib-coverage'; | ||
|
||
const dir = process.env.COVERAGE_DIR; | ||
const reporter = process.env.COVERAGE_REPORTER || 'lcov'; | ||
|
||
console.log('Coverage plugin started'); | ||
|
||
if (!dir && !reporter) { | ||
return console.log('Coverage plugin not configured'); | ||
} | ||
|
||
if (!dir || !reporter) { | ||
console.log('Coverage plugin not fully configured'); | ||
return; | ||
} | ||
|
||
process.on('exit', async () => { | ||
try { | ||
if (!dir) { | ||
throw new Error('No coverage dir'); | ||
} | ||
|
||
if (!reporter) { | ||
throw new Error('No coverage reporter'); | ||
} | ||
console.log('Coverage plugin triggered'); | ||
|
||
const coverageMap = libCoverage.createCoverageMap(globalThis['__coverage__']); | ||
|
||
const configWatermarks = { | ||
statements: [50, 80], | ||
functions: [50, 80], | ||
branches: [50, 80], | ||
lines: [50, 80], | ||
}; | ||
|
||
const context = libReport.createContext({ | ||
dir, | ||
coverageMap, | ||
}); | ||
|
||
const report = reports.create(reporter); | ||
|
||
report.execute(context); | ||
} catch (e) { | ||
console.log('Error', e); | ||
} | ||
}); |
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 |
---|---|---|
|
@@ -26,3 +26,5 @@ flags: | |
|
||
comment: | ||
layout: 'reach, diff, flags' | ||
fixes: | ||
- '/home/runner/work/Rocket.Chat/Rocket.Chat/::' |
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