mirror of
https://github.com/tenrok/OverlayScrollbars.git
synced 2026-06-05 00:22:26 +03:00
update repo structure
This commit is contained in:
@@ -0,0 +1,26 @@
|
||||
module.exports = function (api) {
|
||||
api.cache.using(() => process.env.NODE_ENV);
|
||||
const isJest = api.caller((caller) => !!(caller && caller.name === 'babel-jest'));
|
||||
|
||||
if (isJest) {
|
||||
return {
|
||||
plugins: [
|
||||
'@babel/plugin-transform-modules-commonjs',
|
||||
['@babel/plugin-proposal-private-methods', { loose: false }],
|
||||
],
|
||||
presets: [
|
||||
[
|
||||
'@babel/preset-env',
|
||||
{
|
||||
targets: {
|
||||
node: 'current',
|
||||
},
|
||||
},
|
||||
],
|
||||
'@babel/preset-typescript',
|
||||
],
|
||||
};
|
||||
}
|
||||
|
||||
return {};
|
||||
};
|
||||
@@ -0,0 +1,17 @@
|
||||
const path = require('path');
|
||||
const resolve = require('./resolve');
|
||||
|
||||
// For a detailed explanation regarding each configuration property, visit:
|
||||
// https://jestjs.io/docs/en/configuration.html
|
||||
|
||||
module.exports = {
|
||||
clearMocks: true,
|
||||
coverageDirectory: './.coverage/jest',
|
||||
testEnvironment: 'jsdom',
|
||||
moduleDirectories: resolve.directories,
|
||||
moduleFileExtensions: resolve.extensions.map((ext) => ext.replace(/\./, '')),
|
||||
testPathIgnorePatterns: ['\\\\node_modules\\\\'],
|
||||
displayName: 'jest',
|
||||
setupFilesAfterEnv: [path.resolve(__dirname, './jest.setup.js')],
|
||||
testMatch: ['**/tests/jest/**/*.test.[jt]s?(x)'],
|
||||
};
|
||||
@@ -0,0 +1,3 @@
|
||||
// remove jsdom warning for not implemented second argument for window.getComputedStyle
|
||||
const cmptdStyle = window.getComputedStyle;
|
||||
window.getComputedStyle = (a) => cmptdStyle(a);
|
||||
@@ -0,0 +1,35 @@
|
||||
const { devices } = require('@playwright/test');
|
||||
|
||||
module.exports = {
|
||||
testMatch: /.*\/tests\/playwright\/.*\.test\.[jt]sx?/,
|
||||
timeout: 10 * 60 * 1000,
|
||||
actionTimeout: 300,
|
||||
navigationTimeout: 1000,
|
||||
retries: 0,
|
||||
workers: 4,
|
||||
projects: [
|
||||
{
|
||||
name: 'Chromium',
|
||||
use: {
|
||||
...devices['Desktop Chromium'],
|
||||
headless: false,
|
||||
},
|
||||
},
|
||||
/*
|
||||
{
|
||||
name: 'Firefox',
|
||||
use: {
|
||||
...devices['Desktop Firefox'],
|
||||
headless: false,
|
||||
},
|
||||
},
|
||||
{
|
||||
name: 'Safari',
|
||||
use: {
|
||||
...devices['Desktop Safari'],
|
||||
headless: false,
|
||||
},
|
||||
},
|
||||
*/
|
||||
],
|
||||
};
|
||||
@@ -0,0 +1,4 @@
|
||||
{
|
||||
"extensions": [".json", ".js", "jsx", ".mjs", ".ts", ".tsx"],
|
||||
"directories": ["node_modules", "src"]
|
||||
}
|
||||
Reference in New Issue
Block a user