This is an automated email from the ASF dual-hosted git repository.
elizabeth pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/superset.git
The following commit(s) were added to refs/heads/master by this push:
new b1296a195c test: Convert DatasetList test from jsx to tsx (#22971)
b1296a195c is described below
commit b1296a195c575c274d1aabf202a8736948e6c603
Author: Lyndsi Kay Williams <[email protected]>
AuthorDate: Wed Feb 15 14:09:43 2023 -0600
test: Convert DatasetList test from jsx to tsx (#22971)
---
.../data/dataset/{DatasetList.test.jsx => DatasetList.test.tsx} | 9 ++++++---
1 file changed, 6 insertions(+), 3 deletions(-)
diff --git a/superset-frontend/src/views/CRUD/data/dataset/DatasetList.test.jsx
b/superset-frontend/src/views/CRUD/data/dataset/DatasetList.test.tsx
similarity index 98%
rename from superset-frontend/src/views/CRUD/data/dataset/DatasetList.test.jsx
rename to superset-frontend/src/views/CRUD/data/dataset/DatasetList.test.tsx
index f44e3c2fbf..cf64ee6ac5 100644
--- a/superset-frontend/src/views/CRUD/data/dataset/DatasetList.test.jsx
+++ b/superset-frontend/src/views/CRUD/data/dataset/DatasetList.test.tsx
@@ -84,7 +84,7 @@ fetchMock.get(databaseEndpoint, {
result: [],
});
-async function mountAndWait(props) {
+async function mountAndWait(props: {}) {
const mounted = mount(
<Provider store={store}>
<DatasetList {...props} user={mockUser} />
@@ -97,7 +97,7 @@ async function mountAndWait(props) {
describe('DatasetList', () => {
const mockedProps = {};
- let wrapper;
+ let wrapper: any;
beforeAll(async () => {
wrapper = await mountAndWait(mockedProps);
@@ -255,7 +255,10 @@ describe('RTL', () => {
return mounted;
}
- let isFeatureEnabledMock;
+ let isFeatureEnabledMock: jest.SpyInstance<
+ boolean,
+ [feature: featureFlags.FeatureFlag]
+ >;
beforeEach(async () => {
isFeatureEnabledMock = jest
.spyOn(featureFlags, 'isFeatureEnabled')