refactor: apply repository naming contract
Apply the accepted pre-release package, service, type, directory, and role renames as one repository-wide change.
This commit is contained in:
@@ -1,11 +1,11 @@
|
||||
/**
|
||||
* LayoutService behavior: the cross-plugin panel-action face. Geometry
|
||||
* LayoutController behavior: the cross-plugin panel-action face. Geometry
|
||||
* lives in the entry store (layout-store.spec.ts) — here we assert the
|
||||
* delegation contract: attachPanels wiring, the three actions forwarding, the
|
||||
* unwired fail-loud, and re-attach overwriting a stale action set.
|
||||
*/
|
||||
import { describe, expect, it, vi } from 'vitest'
|
||||
import { LayoutService } from '@deepseek-ai/dsh-client-ui-layout/src/client/service.ts'
|
||||
import { LayoutController } from '@deepseek-ai/dsh-client-ui-layout/src/client/service.ts'
|
||||
import type { PanelActions } from '@deepseek-ai/dsh-client-ui-layout/src/client/service.ts'
|
||||
|
||||
function fakePanels(): PanelActions {
|
||||
@@ -19,9 +19,9 @@ function fakePanels(): PanelActions {
|
||||
}
|
||||
}
|
||||
|
||||
describe('LayoutService', () => {
|
||||
describe('LayoutController', () => {
|
||||
it('forwards the three panel actions to the attached set', () => {
|
||||
const service = new LayoutService()
|
||||
const service = new LayoutController()
|
||||
const panels = fakePanels()
|
||||
service.attachPanels(panels)
|
||||
|
||||
@@ -37,14 +37,14 @@ describe('LayoutService', () => {
|
||||
})
|
||||
|
||||
it('fails loud before the root entry wired its actions', () => {
|
||||
const service = new LayoutService()
|
||||
const service = new LayoutController()
|
||||
expect(() => { service.toggleSidebar() }).toThrow(/panel actions not wired/)
|
||||
expect(() => { service.openDetails() }).toThrow(/panel actions not wired/)
|
||||
expect(() => { service.closeDetails() }).toThrow(/panel actions not wired/)
|
||||
})
|
||||
|
||||
it('re-attach overwrites the stale action set (entry re-register)', () => {
|
||||
const service = new LayoutService()
|
||||
const service = new LayoutController()
|
||||
const stale = fakePanels()
|
||||
const fresh = fakePanels()
|
||||
service.attachPanels(stale)
|
||||
|
||||
Reference in New Issue
Block a user