Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test: fix error on test #91055

Merged
merged 1 commit into from
Nov 1, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ const history = H.createHashHistory();
const withLoadingIndicator: DatabaseDetailsPageProps = {
loading: true,
loaded: false,
lastError: undefined,
name: randomName(),
tables: [],
viewMode: ViewMode.Tables,
Expand Down Expand Up @@ -61,6 +62,7 @@ const withLoadingIndicator: DatabaseDetailsPageProps = {
const withoutData: DatabaseDetailsPageProps = {
loading: false,
loaded: true,
lastError: null,
name: randomName(),
tables: [],
viewMode: ViewMode.Tables,
Expand Down Expand Up @@ -98,6 +100,7 @@ function createTable(): DatabaseDetailsPageDataTable {
details: {
loading: false,
loaded: true,
lastError: null,
columnCount: _.random(5, 42),
indexCount: _.random(1, 6),
userCount: roles.length,
Expand All @@ -112,6 +115,7 @@ function createTable(): DatabaseDetailsPageDataTable {
stats: {
loading: false,
loaded: true,
lastError: null,
replicationSizeInBytes: _.random(1000.0) * 1024 ** _.random(1, 2),
rangeCount: _.random(50, 500),
nodesByRegionString:
Expand All @@ -123,6 +127,7 @@ function createTable(): DatabaseDetailsPageDataTable {
const withData: DatabaseDetailsPageProps = {
loading: false,
loaded: true,
lastError: null,
name: randomName(),
tables: [createTable()],
viewMode: ViewMode.Tables,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ const withLoadingIndicator: DatabaseTablePageProps = {
details: {
loading: true,
loaded: false,
lastError: undefined,
createStatement: "",
replicaCount: 0,
indexNames: [],
Expand All @@ -41,12 +42,14 @@ const withLoadingIndicator: DatabaseTablePageProps = {
stats: {
loading: true,
loaded: false,
lastError: undefined,
sizeInBytes: 0,
rangeCount: 0,
},
indexStats: {
loading: true,
loaded: false,
lastError: undefined,
stats: [],
lastReset: moment("2021-09-04T13:55:00Z"),
},
Expand Down Expand Up @@ -74,6 +77,7 @@ const withData: DatabaseTablePageProps = {
details: {
loading: false,
loaded: true,
lastError: null,
createStatement: `
CREATE TABLE public.${name} (
id UUID NOT NULL,
Expand Down Expand Up @@ -102,6 +106,7 @@ const withData: DatabaseTablePageProps = {
stats: {
loading: false,
loaded: true,
lastError: null,
sizeInBytes: 44040192,
rangeCount: 4200,
nodesByRegionString:
Expand All @@ -110,6 +115,7 @@ const withData: DatabaseTablePageProps = {
indexStats: {
loading: false,
loaded: true,
lastError: null,
stats: [
{
totalReads: 0,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ const history = H.createHashHistory();
const withLoadingIndicator: DatabasesPageProps = {
loading: true,
loaded: false,
lastError: undefined,
automaticStatsCollectionEnabled: true,
databases: [],
sortSetting: {
Expand All @@ -46,6 +47,7 @@ const withLoadingIndicator: DatabasesPageProps = {
const withoutData: DatabasesPageProps = {
loading: false,
loaded: true,
lastError: null,
automaticStatsCollectionEnabled: true,
databases: [],
sortSetting: {
Expand All @@ -70,6 +72,7 @@ const withoutData: DatabasesPageProps = {
const withData: DatabasesPageProps = {
loading: false,
loaded: true,
lastError: null,
showNodeRegionsColumn: true,
automaticStatsCollectionEnabled: true,
sortSetting: {
Expand All @@ -80,6 +83,7 @@ const withData: DatabasesPageProps = {
return {
loading: false,
loaded: true,
lastError: null,
name: randomName(),
sizeInBytes: _.random(1000.0) * 1024 ** _.random(1, 2),
tableCount: _.random(5, 100),
Expand Down