Skip to content

Commit

Permalink
Adjustments for NC28 (#239)
Browse files Browse the repository at this point in the history
* Update CI/CD for NC28

* Update code to be NC28 compatible
  • Loading branch information
R0Wi authored Dec 17, 2023
1 parent 4e0187b commit e23b97f
Show file tree
Hide file tree
Showing 15 changed files with 12,262 additions and 33,158 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/phpunit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
matrix:
php-versions: ['8.1']
databases: ['sqlite']
server-versions: ['master']
server-versions: ['stable28']

name: php${{ matrix.php-versions }}-${{ matrix.databases }}

Expand Down Expand Up @@ -76,7 +76,7 @@ jobs:
matrix:
php-versions: ['8.0', '8.1', '8.2']
databases: ['mysql']
server-versions: ['master']
server-versions: ['stable28']

name: php${{ matrix.php-versions }}-${{ matrix.databases }}

Expand Down Expand Up @@ -141,7 +141,7 @@ jobs:
matrix:
php-versions: ['8.1']
databases: ['pgsql']
server-versions: ['master']
server-versions: ['stable28']

name: php${{ matrix.php-versions }}-${{ matrix.databases }}

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/psalm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:

strategy:
matrix:
ocp-version: [ 'dev-master' ]
ocp-version: [ 'dev-stable28' ]
php-version: [ '8.0', '8.1', '8.2' ]

name: Nextcloud ${{ matrix.ocp-version }} PHP${{ matrix.php-version }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/sonarqube.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
matrix:
php-versions: ['8.2']
databases: ['sqlite']
server-versions: ['master']
server-versions: ['stable28']

name: php${{ matrix.php-versions }}-${{ matrix.databases }}-COVERAGE

Expand Down
98 changes: 74 additions & 24 deletions jest.config.js
Original file line number Diff line number Diff line change
@@ -1,25 +1,75 @@
// These modules will be transformed to commonjs modules
const ignorePatterns = [
'ansi-regex',
'@mdi/svg',
'bail',
'comma-separated-tokens',
'char-regex',
'decode-named-character-reference',
'devlop',
'escape-string-regexp',
'hast-.*',
'is-.*',
'mdast-.*',
'micromark',
'micromark-.*',
'property-information',
'rehype-.*',
'remark-.*',
'space-separated-tokens',
'string-length',
'strip-ansi',
'trim-lines',
'trough',
'tributejs',
'unified',
'unist-.*',
'vfile',
'vfile-.*',
'vue-material-design-icons',
'web-namespaces',
]

module.exports = {
preset: '@vue/cli-plugin-unit-jest',
collectCoverage: true,
collectCoverageFrom: [
"src/**/*.{js,vue}",
"!src/test/**",
"!**/node_modules/**"
],
coverageReporters: [
"text-summary",
"json",
"lcov",
"html"
],
testMatch: [
"**/src/test/*.spec.js",
"**/src/test/**/*.spec.js"
],
transformIgnorePatterns: [
"node_modules\/(?!(vue-material-design-icons)\/)",
//"node_modules/(?!@babel)"
],
setupFilesAfterEnv: ['<rootDir>/src/test/setup-jest.js']
}

collectCoverage: true,

collectCoverageFrom: [
'src/**/*.{js,vue}',
'!src/test/**',
'!**/node_modules/**',
],

coverageReporters: [
'text-summary',
'json',
'lcov',
'html',
],

testMatch: [
'**/src/test/*.spec.js',
'**/src/test/**/*.spec.js'
],

transformIgnorePatterns: [
'node_modules/(?!(' + ignorePatterns.join('|') + ')/)',
],

setupFilesAfterEnv: ['<rootDir>/src/test/setup-jest.js'],

testEnvironment: 'jest-environment-jsdom',

moduleFileExtensions: [
'js',
'vue',
],

moduleNameMapper: {
'\\.(css|scss)$': 'jest-transform-stub',
},

transform: {
'\\.js$': 'babel-jest',
'\\.vue$': '@vue/vue2-jest',
},
}
Loading

0 comments on commit e23b97f

Please sign in to comment.