Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
Metabase
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Engineering Digital Service
Metabase
Commits
20674a66
Unverified
Commit
20674a66
authored
8 months ago
by
Kamil Mielnik
Committed by
GitHub
8 months ago
Browse files
Options
Downloads
Patches
Plain Diff
Repro #34350 - Unable to switch question to query table in another database (#44969)
* Add repro for #34350 * Reduce diff
parent
2bf64231
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
e2e/test/scenarios/question/notebook-data-source.cy.spec.ts
+36
-11
36 additions, 11 deletions
e2e/test/scenarios/question/notebook-data-source.cy.spec.ts
with
36 additions
and
11 deletions
e2e/test/scenarios/question/notebook-data-source.cy.spec.ts
+
36
−
11
View file @
20674a66
...
...
@@ -28,6 +28,8 @@ import {
visitModel
,
visitQuestion
,
visualize
,
openOrdersTable
,
queryBuilderMain
,
}
from
"
e2e/support/helpers
"
;
import
{
checkNotNull
}
from
"
metabase/lib/types
"
;
...
...
@@ -393,6 +395,29 @@ describe("scenarios > notebook > data source", { tags: "@OSS" }, () => {
});
});
describe
(
"
issue 34350
"
,
{
tags
:
"
@external
"
},
()
=>
{
beforeEach
(()
=>
{
restore
(
"
postgres-12
"
);
cy
.
signInAsAdmin
();
});
it
(
"
works after changing question's source table to a one from a different database (metabase#34350)
"
,
()
=>
{
openOrdersTable
({
mode
:
"
notebook
"
});
openDataSelector
();
entityPickerModal
().
within
(()
=>
{
cy
.
findByText
(
"
QA Postgres12
"
).
click
();
cy
.
findByText
(
"
Orders
"
).
click
();
});
visualize
();
queryBuilderMain
()
.
findByText
(
"
There was a problem with your question
"
)
.
should
(
"
not.exist
"
);
cy
.
findAllByTestId
(
"
cell-data
"
).
should
(
"
contain
"
,
"
37.65
"
);
});
});
describe
(
"
issue 28106
"
,
()
=>
{
beforeEach
(()
=>
{
const
dialect
=
"
postgres
"
;
...
...
@@ -417,22 +442,22 @@ describe("issue 28106", () => {
.
findByTestId
(
"
scroll-container
"
)
.
as
(
"
schemasList
"
);
// the list is virtualized and the scrollbar height changes during scrolling (metabase#44966)
// that's why we need to scroll twice and wait
cy
.
get
(
"
@schemasList
"
).
scrollTo
(
"
bottom
"
);
cy
.
wait
(
100
);
cy
.
get
(
"
@schemasList
"
).
scrollTo
(
"
bottom
"
);
// The list is virtualized and the scrollbar height changes during scrolling (metabase#44966)
// that's why we need to scroll and wait multiple times.
// Test is flaky because of this - that's why there are 3 attempts.
for
(
let
i
=
0
;
i
<
3
;
++
i
)
{
cy
.
get
(
"
@schemasList
"
).
scrollTo
(
"
bottom
"
);
cy
.
wait
(
100
);
}
// assert scrolling worked and the last item is visible
entityPickerModalItem
(
1
,
"
Public
"
).
should
(
"
be.visible
"
);
// simulate scrolling up using mouse wheel 3 times
cy
.
get
(
"
@schemasList
"
).
realMouseWheel
({
deltaY
:
-
100
});
cy
.
wait
(
100
);
cy
.
get
(
"
@schemasList
"
).
realMouseWheel
({
deltaY
:
-
100
});
cy
.
wait
(
100
);
cy
.
get
(
"
@schemasList
"
).
realMouseWheel
({
deltaY
:
-
100
});
cy
.
wait
(
100
);
for
(
let
i
=
0
;
i
<
3
;
++
i
)
{
cy
.
get
(
"
@schemasList
"
).
realMouseWheel
({
deltaY
:
-
100
});
cy
.
wait
(
100
);
}
// assert first item does not exist - this means the list has not been scrolled to the top
cy
.
findByText
(
"
Domestic
"
).
should
(
"
not.exist
"
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment