Skip to content

Commit

Permalink
resolving merge conflict
Browse files Browse the repository at this point in the history
  • Loading branch information
prklm10 committed Sep 25, 2023
2 parents fa8919e + f520fbe commit 8a90a36
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 10 deletions.
3 changes: 1 addition & 2 deletions packages/config/src/utils/normalize.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,7 @@ import { getSchema } from '../validate.js';
const CAMELCASE_MAP = new Map([
['css', 'CSS'],
['javascript', 'JavaScript'],
['dom', 'DOM'],
['xpaths', 'XPaths']
['dom', 'DOM']
]);

// Regular expression that matches words from boundaries or consecutive casing
Expand Down
6 changes: 3 additions & 3 deletions packages/config/test/index.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -1212,7 +1212,7 @@ describe('PercyConfig', () => {
enableJavaScript: false,
disableShadowDOM: true,
cliEnableJavaScript: true,
ignoreRegionXPaths: [''],
ignoreRegionXpaths: [''],
enableLayout: false
});
});
Expand All @@ -1226,7 +1226,7 @@ describe('PercyConfig', () => {
enableJavaScript: false,
disableShadowDOM: true,
cliEnableJavaScript: true,
ignoreRegionXPaths: [''],
ignoreRegionXpaths: [''],
enableLayout: false
}, { kebab: true })).toEqual({
'foo-bar': 'baz',
Expand All @@ -1250,7 +1250,7 @@ describe('PercyConfig', () => {
enableJavaScript: false,
disableShadowDOM: true,
cliEnableJavaScript: true,
ignoreRegionXPaths: [''],
ignoreRegionXpaths: [''],
enableLayout: false
}, { snake: true })).toEqual({
foo_bar: 'baz',
Expand Down
2 changes: 1 addition & 1 deletion packages/core/src/config.js
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ export const configSchema = {
type: 'string'
}
},
considerRegionXPaths: {
considerRegionXpaths: {
type: 'array',
items: {
type: 'string'
Expand Down
2 changes: 1 addition & 1 deletion packages/core/src/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ export function percyAutomateRequestHandler(req, percy) {
ignoreRegionSelectors: percy.config.snapshot.ignoreRegions?.ignoreRegionSelectors,
ignoreRegionXpaths: percy.config.snapshot.ignoreRegions?.ignoreRegionXpaths,
considerRegionSelectors: percy.config.snapshot.considerRegions?.considerRegionSelectors,
considerRegionXPaths: percy.config.snapshot.considerRegions?.considerRegionXPaths
considerRegionXpaths: percy.config.snapshot.considerRegions?.considerRegionXpaths
},
camelCasedOptions
], (path, prev, next) => {
Expand Down
6 changes: 3 additions & 3 deletions packages/core/test/api.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -277,7 +277,7 @@ describe('API Server', () => {
percy.config.snapshot.percyCSS = '.global { color: blue }';
percy.config.snapshot.freezeAnimation = false;
percy.config.snapshot.ignoreRegions = { ignoreRegionSelectors: ['.selector-global'] };
percy.config.snapshot.considerRegions = { considerRegionXPaths: ['/xpath-global'] };
percy.config.snapshot.considerRegions = { considerRegionXpaths: ['/xpath-global'] };

await expectAsync(request('/percy/automateScreenshot', {
body: {
Expand All @@ -302,8 +302,8 @@ describe('API Server', () => {
freezeAnimation: true,
percyCSS: '.global { color: blue }\n.percy-screenshot: { color: red }',
ignoreRegionSelectors: ['.selector-global'],
ignoreRegionXPaths: ['/xpath-per-screenshot'],
considerRegionXPaths: ['/xpath-global', '/xpath-per-screenshot']
ignoreRegionXpaths: ['/xpath-per-screenshot'],
considerRegionXpaths: ['/xpath-global', '/xpath-per-screenshot']
}
}));

Expand Down

0 comments on commit 8a90a36

Please sign in to comment.