feat(dashboard): complete React cutover
This commit is contained in:
1 parent
d5f0175dc2
commit
ec0cd1318b
13 files changed
+50
-4291
No files matched your search
@@ -11,17 +11,14 @@ describe('resolveDashboardAssets', () => {
|
||||
expect(resolveDashboardAssets(workspace, fileExists)).toEqual({
|
||||
directory: path.dirname(reactIndex),
|
||||
indexFile: reactIndex,
|
||||
isLegacy: false,
|
||||
});
|
||||
});
|
||||
|
||||
it('falls back to the legacy dashboard during incremental migration', () => {
|
||||
it('fails clearly when the production React build is missing', () => {
|
||||
const workspace = path.resolve('workspace');
|
||||
|
||||
expect(resolveDashboardAssets(workspace, () => false)).toEqual({
|
||||
directory: path.join(workspace, 'public'),
|
||||
indexFile: path.join(workspace, 'public', 'index.html'),
|
||||
isLegacy: true,
|
||||
});
|
||||
expect(() => resolveDashboardAssets(workspace, () => false)).toThrow(
|
||||
'React dashboard build is missing',
|
||||
);
|
||||
});
|
||||
});
|
||||
Reference in new issue
Block a user