Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
N
nexpie-grafana-theme
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Registry
Registry
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kornkitt Poolsup
nexpie-grafana-theme
Commits
23471346
Commit
23471346
authored
Jan 16, 2019
by
Johannes Schill
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
test: Update snapshots and mocks
parent
3ca7523a
Hide whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
313 additions
and
147 deletions
+313
-147
packages/grafana-ui/src/components/CustomScrollbar/__snapshots__/CustomScrollbar.test.tsx.snap
+2
-2
public/app/features/api-keys/ApiKeysPage.test.tsx
+8
-1
public/app/features/api-keys/__snapshots__/ApiKeysPage.test.tsx.snap
+132
-106
public/app/features/datasources/DataSourcesListPage.test.tsx
+8
-1
public/app/features/datasources/__snapshots__/DataSourcesListPage.test.tsx.snap
+20
-2
public/app/features/org/OrgDetailsPage.test.tsx
+8
-1
public/app/features/org/__snapshots__/OrgDetailsPage.test.tsx.snap
+49
-23
public/app/features/plugins/PluginListPage.test.tsx
+8
-1
public/app/features/plugins/__snapshots__/PluginListPage.test.tsx.snap
+20
-2
public/app/features/teams/TeamList.test.tsx
+8
-1
public/app/features/teams/__snapshots__/TeamList.test.tsx.snap
+22
-4
public/app/features/users/UsersListPage.test.tsx
+8
-1
public/app/features/users/__snapshots__/UsersListPage.test.tsx.snap
+20
-2
No files found.
packages/grafana-ui/src/components/CustomScrollbar/__snapshots__/CustomScrollbar.test.tsx.snap
View file @
23471346
...
@@ -7,7 +7,7 @@ exports[`CustomScrollbar renders correctly 1`] = `
...
@@ -7,7 +7,7 @@ exports[`CustomScrollbar renders correctly 1`] = `
Object {
Object {
"height": "auto",
"height": "auto",
"maxHeight": "100%",
"maxHeight": "100%",
"minHeight":
"0"
,
"minHeight":
0
,
"overflow": "hidden",
"overflow": "hidden",
"position": "relative",
"position": "relative",
"width": "100%",
"width": "100%",
...
@@ -24,7 +24,7 @@ exports[`CustomScrollbar renders correctly 1`] = `
...
@@ -24,7 +24,7 @@ exports[`CustomScrollbar renders correctly 1`] = `
"marginBottom": 0,
"marginBottom": 0,
"marginRight": 0,
"marginRight": 0,
"maxHeight": "calc(100% + 0px)",
"maxHeight": "calc(100% + 0px)",
"minHeight":
"calc(0 + 0px)"
,
"minHeight":
0
,
"overflow": "scroll",
"overflow": "scroll",
"position": "relative",
"position": "relative",
"right": undefined,
"right": undefined,
...
...
public/app/features/api-keys/ApiKeysPage.test.tsx
View file @
23471346
...
@@ -6,7 +6,14 @@ import { getMultipleMockKeys, getMockKey } from './__mocks__/apiKeysMock';
...
@@ -6,7 +6,14 @@ import { getMultipleMockKeys, getMockKey } from './__mocks__/apiKeysMock';
const
setup
=
(
propOverrides
?:
object
)
=>
{
const
setup
=
(
propOverrides
?:
object
)
=>
{
const
props
:
Props
=
{
const
props
:
Props
=
{
navModel
:
{}
as
NavModel
,
navModel
:
{
main
:
{
text
:
'Configuration'
},
node
:
{
text
:
'Api Keys'
}
}
as
NavModel
,
apiKeys
:
[]
as
ApiKey
[],
apiKeys
:
[]
as
ApiKey
[],
searchQuery
:
''
,
searchQuery
:
''
,
hasFetched
:
false
,
hasFetched
:
false
,
...
...
public/app/features/api-keys/__snapshots__/ApiKeysPage.test.tsx.snap
View file @
23471346
// Jest Snapshot v1, https://goo.gl/fbAQLP
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`Render should render API keys table if there are any keys 1`] = `
exports[`Render should render API keys table if there are any keys 1`] = `
<div>
<Page
title="Configuration: Api Keys"
>
<PageHeader
<PageHeader
model={Object {}}
model={
Object {
"main": Object {
"text": "Configuration",
},
"node": Object {
"text": "Api Keys",
},
}
}
/>
/>
<Page
Loader
<Page
Contents
pageName="Api keys"
isLoading={true}
/>
/>
</
div
>
</
Page
>
`;
`;
exports[`Render should render CTA if there are no API keys 1`] = `
exports[`Render should render CTA if there are no API keys 1`] = `
<div>
<Page
title="Configuration: Api Keys"
>
<PageHeader
<PageHeader
model={Object {}}
model={
Object {
"main": Object {
"text": "Configuration",
},
"node": Object {
"text": "Api Keys",
},
}
}
/>
/>
<
div
<
PageContents
className="page-container page-body"
isLoading={false}
>
>
<EmptyListCTA
<div
model={
className="page-container page-body"
Object {
"buttonIcon": "fa fa-plus",
"buttonLink": "#",
"buttonTitle": " New API Key",
"onClick": [Function],
"proTip": "Remember you can provide view-only API access to other applications.",
"proTipLink": "",
"proTipLinkTitle": "",
"proTipTarget": "_blank",
"title": "You haven't added any API Keys yet.",
}
}
/>
<Component
in={false}
>
>
<div
<EmptyListCTA
className="cta-form"
model={
Object {
"buttonIcon": "fa fa-plus",
"buttonLink": "#",
"buttonTitle": " New API Key",
"onClick": [Function],
"proTip": "Remember you can provide view-only API access to other applications.",
"proTipLink": "",
"proTipLinkTitle": "",
"proTipTarget": "_blank",
"title": "You haven't added any API Keys yet.",
}
}
/>
<Component
in={false}
>
>
<button
<div
className="cta-form__close btn btn-transparent"
className="cta-form"
onClick={[Function]}
>
<i
className="fa fa-close"
/>
</button>
<h5>
Add API Key
</h5>
<form
className="gf-form-group"
onSubmit={[Function]}
>
>
<div
<button
className="gf-form-inline"
className="cta-form__close btn btn-transparent"
onClick={[Function]}
>
<i
className="fa fa-close"
/>
</button>
<h5>
Add API Key
</h5>
<form
className="gf-form-group"
onSubmit={[Function]}
>
>
<div
<div
className="gf-form max-width-21"
className="gf-form-inline"
>
<span
className="gf-form-label"
>
Key name
</span>
<input
className="gf-form-input"
onChange={[Function]}
placeholder="Name"
type="text"
value=""
/>
</div>
<div
className="gf-form"
>
>
<
span
<
div
className="gf-form
-label
"
className="gf-form
max-width-21
"
>
>
Role
<span
</span>
className="gf-form-label"
<span
>
className="gf-form-select-wrapper"
Key name
>
</span
>
<
selec
t
<
inpu
t
className="gf-form-input
gf-size-auto
"
className="gf-form-input"
onChange={[Function]}
onChange={[Function]}
value="Viewer"
placeholder="Name"
type="text"
value=""
/>
</div>
<div
className="gf-form"
>
<span
className="gf-form-label"
>
>
<option
Role
key="Viewer"
</span>
label="Viewer"
<span
className="gf-form-select-wrapper"
>
<select
className="gf-form-input gf-size-auto"
onChange={[Function]}
value="Viewer"
value="Viewer"
>
>
Viewer
<option
</option>
key="Viewer"
<option
label="Viewer"
key="Editor"
value="Viewer"
label="Editor"
>
value="Editor"
Viewer
>
</option>
Editor
<option
</option>
key="Editor"
<option
label="Editor"
key="Admin"
value="Editor"
label="Admin"
>
value="Admin"
Editor
>
</option>
Admin
<option
</option>
key="Admin"
</select>
label="Admin"
</span>
value="Admin"
</div>
>
<div
Admin
className="gf-form"
</option>
>
</select>
<button
</span>
className="btn gf-form-btn btn-success"
</div>
<div
className="gf-form"
>
>
Add
<button
</button>
className="btn gf-form-btn btn-success"
>
Add
</button>
</div>
</div>
</div>
</
div
>
</
form
>
</
form
>
</
div
>
</
div
>
</
Component
>
</
Component
>
</
div
>
</
div
>
</
PageContents
>
</
div
>
</
Page
>
`;
`;
public/app/features/datasources/DataSourcesListPage.test.tsx
View file @
23471346
...
@@ -10,7 +10,14 @@ const setup = (propOverrides?: object) => {
...
@@ -10,7 +10,14 @@ const setup = (propOverrides?: object) => {
dataSources
:
[]
as
DataSource
[],
dataSources
:
[]
as
DataSource
[],
layoutMode
:
LayoutModes
.
Grid
,
layoutMode
:
LayoutModes
.
Grid
,
loadDataSources
:
jest
.
fn
(),
loadDataSources
:
jest
.
fn
(),
navModel
:
{}
as
NavModel
,
navModel
:
{
main
:
{
text
:
'Configuration'
},
node
:
{
text
:
'Data Sources'
}
}
as
NavModel
,
dataSourcesCount
:
0
,
dataSourcesCount
:
0
,
searchQuery
:
''
,
searchQuery
:
''
,
setDataSourcesSearchQuery
:
jest
.
fn
(),
setDataSourcesSearchQuery
:
jest
.
fn
(),
...
...
public/app/features/datasources/__snapshots__/DataSourcesListPage.test.tsx.snap
View file @
23471346
...
@@ -5,7 +5,16 @@ exports[`Render should render action bar and datasources 1`] = `
...
@@ -5,7 +5,16 @@ exports[`Render should render action bar and datasources 1`] = `
title="Configuration: Data Sources"
title="Configuration: Data Sources"
>
>
<PageHeader
<PageHeader
model={Object {}}
model={
Object {
"main": Object {
"text": "Configuration",
},
"node": Object {
"text": "Data Sources",
},
}
}
/>
/>
<PageContents
<PageContents
isLoading={false}
isLoading={false}
...
@@ -154,7 +163,16 @@ exports[`Render should render component 1`] = `
...
@@ -154,7 +163,16 @@ exports[`Render should render component 1`] = `
title="Configuration: Data Sources"
title="Configuration: Data Sources"
>
>
<PageHeader
<PageHeader
model={Object {}}
model={
Object {
"main": Object {
"text": "Configuration",
},
"node": Object {
"text": "Data Sources",
},
}
}
/>
/>
<PageContents
<PageContents
isLoading={true}
isLoading={true}
...
...
public/app/features/org/OrgDetailsPage.test.tsx
View file @
23471346
...
@@ -6,7 +6,14 @@ import { NavModel, Organization } from '../../types';
...
@@ -6,7 +6,14 @@ import { NavModel, Organization } from '../../types';
const
setup
=
(
propOverrides
?:
object
)
=>
{
const
setup
=
(
propOverrides
?:
object
)
=>
{
const
props
:
Props
=
{
const
props
:
Props
=
{
organization
:
{}
as
Organization
,
organization
:
{}
as
Organization
,
navModel
:
{}
as
NavModel
,
navModel
:
{
main
:
{
text
:
'Configuration'
},
node
:
{
text
:
'Org details'
}
}
as
NavModel
,
loadOrganization
:
jest
.
fn
(),
loadOrganization
:
jest
.
fn
(),
setOrganizationName
:
jest
.
fn
(),
setOrganizationName
:
jest
.
fn
(),
updateOrganization
:
jest
.
fn
(),
updateOrganization
:
jest
.
fn
(),
...
...
public/app/features/org/__snapshots__/OrgDetailsPage.test.tsx.snap
View file @
23471346
// Jest Snapshot v1, https://goo.gl/fbAQLP
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`Render should render component 1`] = `
exports[`Render should render component 1`] = `
<div>
<Page
title="Configuration: Org details"
>
<PageHeader
<PageHeader
model={Object {}}
model={
Object {
"main": Object {
"text": "Configuration",
},
"node": Object {
"text": "Org details",
},
}
}
/>
/>
<
div
<
PageContents
className="page-container page-body"
isLoading={true}
>
>
<
PageLoader
<
div
pageName="Organization
"
className="page-container page-body
"
/>
/>
</
div
>
</
PageContents
>
</
div
>
</
Page
>
`;
`;
exports[`Render should render organization and preferences 1`] = `
exports[`Render should render organization and preferences 1`] = `
<div>
<Page
title="Configuration: Org details"
>
<PageHeader
<PageHeader
model={Object {}}
model={
Object {
"main": Object {
"text": "Configuration",
},
"node": Object {
"text": "Org details",
},
}
}
/>
/>
<
div
<
PageContents
className="page-container page-body"
isLoading={false}
>
>
<div>
<div
<OrgProfile
className="page-container page-body"
onOrgNameChange={[Function]}
>
onSubmit={[Function]}
<div>
orgName="Cool org"
<OrgProfile
/>
onOrgNameChange={[Function]}
<SharedPreferences
onSubmit={[Function]}
resourceUri="org"
orgName="Cool org"
/>
/>
<SharedPreferences
resourceUri="org"
/>
</div>
</div>
</div>
</
div
>
</
PageContents
>
</
div
>
</
Page
>
`;
`;
public/app/features/plugins/PluginListPage.test.tsx
View file @
23471346
...
@@ -6,7 +6,14 @@ import { LayoutModes } from '../../core/components/LayoutSelector/LayoutSelector
...
@@ -6,7 +6,14 @@ import { LayoutModes } from '../../core/components/LayoutSelector/LayoutSelector
const
setup
=
(
propOverrides
?:
object
)
=>
{
const
setup
=
(
propOverrides
?:
object
)
=>
{
const
props
:
Props
=
{
const
props
:
Props
=
{
navModel
:
{}
as
NavModel
,
navModel
:
{
main
:
{
text
:
'Configuration'
},
node
:
{
text
:
'Plugins'
}
}
as
NavModel
,
plugins
:
[]
as
Plugin
[],
plugins
:
[]
as
Plugin
[],
searchQuery
:
''
,
searchQuery
:
''
,
setPluginsSearchQuery
:
jest
.
fn
(),
setPluginsSearchQuery
:
jest
.
fn
(),
...
...
public/app/features/plugins/__snapshots__/PluginListPage.test.tsx.snap
View file @
23471346
...
@@ -5,7 +5,16 @@ exports[`Render should render component 1`] = `
...
@@ -5,7 +5,16 @@ exports[`Render should render component 1`] = `
title="Configuration: Plugins"
title="Configuration: Plugins"
>
>
<PageHeader
<PageHeader
model={Object {}}
model={
Object {
"main": Object {
"text": "Configuration",
},
"node": Object {
"text": "Plugins",
},
}
}
/>
/>
<PageContents
<PageContents
isLoading={true}
isLoading={true}
...
@@ -31,7 +40,16 @@ exports[`Render should render list 1`] = `
...
@@ -31,7 +40,16 @@ exports[`Render should render list 1`] = `
title="Configuration: Plugins"
title="Configuration: Plugins"
>
>
<PageHeader
<PageHeader
model={Object {}}
model={
Object {
"main": Object {
"text": "Configuration",
},
"node": Object {
"text": "Plugins",
},
}
}
/>
/>
<PageContents
<PageContents
isLoading={false}
isLoading={false}
...
...
public/app/features/teams/TeamList.test.tsx
View file @
23471346
...
@@ -6,7 +6,14 @@ import { getMockTeam, getMultipleMockTeams } from './__mocks__/teamMocks';
...
@@ -6,7 +6,14 @@ import { getMockTeam, getMultipleMockTeams } from './__mocks__/teamMocks';
const
setup
=
(
propOverrides
?:
object
)
=>
{
const
setup
=
(
propOverrides
?:
object
)
=>
{
const
props
:
Props
=
{
const
props
:
Props
=
{
navModel
:
{}
as
NavModel
,
navModel
:
{
main
:
{
text
:
'Configuration'
},
node
:
{
text
:
'Team List'
}
}
as
NavModel
,
teams
:
[]
as
Team
[],
teams
:
[]
as
Team
[],
loadTeams
:
jest
.
fn
(),
loadTeams
:
jest
.
fn
(),
deleteTeam
:
jest
.
fn
(),
deleteTeam
:
jest
.
fn
(),
...
...
public/app/features/teams/__snapshots__/TeamList.test.tsx.snap
View file @
23471346
...
@@ -2,10 +2,19 @@
...
@@ -2,10 +2,19 @@
exports[`Render should render component 1`] = `
exports[`Render should render component 1`] = `
<Page
<Page
title="Configuration: Team
s
"
title="Configuration: Team
List
"
>
>
<PageHeader
<PageHeader
model={Object {}}
model={
Object {
"main": Object {
"text": "Configuration",
},
"node": Object {
"text": "Team List",
},
}
}
/>
/>
<PageContents
<PageContents
isLoading={true}
isLoading={true}
...
@@ -15,10 +24,19 @@ exports[`Render should render component 1`] = `
...
@@ -15,10 +24,19 @@ exports[`Render should render component 1`] = `
exports[`Render should render teams table 1`] = `
exports[`Render should render teams table 1`] = `
<Page
<Page
title="Configuration: Team
s
"
title="Configuration: Team
List
"
>
>
<PageHeader
<PageHeader
model={Object {}}
model={
Object {
"main": Object {
"text": "Configuration",
},
"node": Object {
"text": "Team List",
},
}
}
/>
/>
<PageContents
<PageContents
isLoading={false}
isLoading={false}
...
...
public/app/features/users/UsersListPage.test.tsx
View file @
23471346
...
@@ -11,7 +11,14 @@ jest.mock('../../core/app_events', () => ({
...
@@ -11,7 +11,14 @@ jest.mock('../../core/app_events', () => ({
const
setup
=
(
propOverrides
?:
object
)
=>
{
const
setup
=
(
propOverrides
?:
object
)
=>
{
const
props
:
Props
=
{
const
props
:
Props
=
{
navModel
:
{}
as
NavModel
,
navModel
:
{
main
:
{
text
:
'Configuration'
},
node
:
{
text
:
'Users'
}
}
as
NavModel
,
users
:
[]
as
OrgUser
[],
users
:
[]
as
OrgUser
[],
invitees
:
[]
as
Invitee
[],
invitees
:
[]
as
Invitee
[],
searchQuery
:
''
,
searchQuery
:
''
,
...
...
public/app/features/users/__snapshots__/UsersListPage.test.tsx.snap
View file @
23471346
...
@@ -5,7 +5,16 @@ exports[`Render should render List page 1`] = `
...
@@ -5,7 +5,16 @@ exports[`Render should render List page 1`] = `
title="Configuration: Users"
title="Configuration: Users"
>
>
<PageHeader
<PageHeader
model={Object {}}
model={
Object {
"main": Object {
"text": "Configuration",
},
"node": Object {
"text": "Users",
},
}
}
/>
/>
<PageContents
<PageContents
isLoading={false}
isLoading={false}
...
@@ -28,7 +37,16 @@ exports[`Render should render component 1`] = `
...
@@ -28,7 +37,16 @@ exports[`Render should render component 1`] = `
title="Configuration: Users"
title="Configuration: Users"
>
>
<PageHeader
<PageHeader
model={Object {}}
model={
Object {
"main": Object {
"text": "Configuration",
},
"node": Object {
"text": "Users",
},
}
}
/>
/>
<PageContents
<PageContents
isLoading={true}
isLoading={true}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment