@@ -9,24 +9,15 @@ describe('matchAppRoute', () => {
|
||||
});
|
||||
});
|
||||
|
||||
it('routes item editor paths to the preset editor items tab', () => {
|
||||
it('routes deprecated editor paths back to the main game', () => {
|
||||
expect(matchAppRoute('/item-editor/tools')).toEqual({
|
||||
kind: 'preset-editor',
|
||||
initialTab: 'items',
|
||||
kind: 'game',
|
||||
});
|
||||
});
|
||||
|
||||
it('routes behavior editor paths to the functions tab', () => {
|
||||
expect(matchAppRoute('/behavior-editor')).toEqual({
|
||||
kind: 'preset-editor',
|
||||
initialTab: 'functions',
|
||||
kind: 'game',
|
||||
});
|
||||
});
|
||||
|
||||
it('accepts nested preset editor paths with trailing slashes', () => {
|
||||
expect(matchAppRoute('/NPC-EDITOR/profiles/')).toEqual({
|
||||
kind: 'preset-editor',
|
||||
initialTab: 'npcs',
|
||||
kind: 'game',
|
||||
});
|
||||
});
|
||||
|
||||
@@ -35,4 +26,10 @@ describe('matchAppRoute', () => {
|
||||
kind: 'game',
|
||||
});
|
||||
});
|
||||
|
||||
it('keeps the sprite tool route', () => {
|
||||
expect(matchAppRoute('/sprite-tool')).toEqual({
|
||||
kind: 'qwen-sprite-tool',
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user