Skip to content

Commit 9045620

Browse files
authored
Move static assets to public (#78)
1 parent bf31a17 commit 9045620

File tree

11 files changed

+13
-15
lines changed

11 files changed

+13
-15
lines changed

__mocks__/dummy.ts

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,3 @@ export class Dummy extends Error {
77
super('Dummy file for exports');
88
}
99
}
10-
11-
export function useResolvedExtensions(): any[] {
12-
return [undefined, undefined, undefined];
13-
}
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# Static mock files, representing k8s API server responces
2+
3+
- URL paths are prefixed by `/api/kubernetes`
4+
- GET, POST, PATCH, PUT share the same resources path
File renamed without changes.
File renamed without changes.

src/components/Utils/ConditionLabel/ConditionLabel.test.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import * as React from 'react';
22

33
import { cleanup, fireEvent, render, screen } from '@testing-library/react';
44

5-
import { conditionsMock } from './tests/mocks';
5+
import { conditionsMock } from './__mocks__/conditionsMock';
66
import { ConditionLabel } from './ConditionLabel';
77

88
afterEach(cleanup);
File renamed without changes.

src/components/Utils/ConditionLabelList/ConditionLabelList.test.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import * as React from 'react';
22

33
import { cleanup, render } from '@testing-library/react';
44

5-
import { conditionsMock } from './tests/mocks';
5+
import { conditionsMock } from './__mocks__/conditionsMock';
66
import { ConditionLabelList } from './ConditionLabelList';
77

88
afterEach(cleanup);
File renamed without changes.

styleguide.config.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ module.exports = {
2525
propsParser: require('react-docgen-typescript').withDefaultConfig().parse,
2626
styleguideDir: 'docs-build',
2727
ignore: [
28-
'**/__tests__/**',
29-
'**/tests/**',
28+
'**/__snapshots__/**',
29+
'**/__mocks__/**',
3030
'**/*.test.{js,jsx,ts,tsx}',
3131
'**/*.d.ts',
3232
'src/components/index.ts',
@@ -59,5 +59,5 @@ module.exports = {
5959
template: {
6060
favicon: './favicon-32x32.png',
6161
},
62-
assetsDir: path.join(__dirname, 'styleguide/assets'),
62+
assetsDir: path.join(__dirname, 'public'),
6363
};

styleguide.config.proxy.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,8 @@ module.exports = {
2626
propsParser: require('react-docgen-typescript').withDefaultConfig().parse,
2727
styleguideDir: 'docs-build',
2828
ignore: [
29-
'**/__tests__/**',
30-
'**/tests/**',
29+
'**/__snapshots__/**',
30+
'**/__mocks__/**',
3131
'**/*.test.{js,jsx,ts,tsx}',
3232
'**/*.d.ts',
3333
'src/components/index.ts',
@@ -60,7 +60,7 @@ module.exports = {
6060
template: {
6161
favicon: './favicon-32x32.png',
6262
},
63-
assetsDir: path.join(__dirname, 'styleguide/assets'),
63+
assetsDir: path.join(__dirname, 'public'),
6464
configureServer(app) {
6565
app.use(
6666
'/api/kubernetes',

0 commit comments

Comments
 (0)