Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions e2e/tests/terminal/shell-terminal.spec.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
/**
* OS Shell Terminal Tests
*
* The SHELL tab of the bottom panel: real shells running in the project
* folder, next to the built-in command terminal (TERMINAL tab).
* The TERMINAL tab of the bottom panel: real shells running in the project
* folder, next to the built-in command console (CONSOLE tab).
*/

import { Page } from '@playwright/test';
Expand All @@ -12,7 +12,7 @@ import { openProject } from '../../helpers/window.helper';
const PROJECT = 'test_project';

const shellTab = (window: Page) =>
window.getByRole('button', { name: 'SHELL', exact: true });
window.getByRole('button', { name: 'TERMINAL', exact: true });
const terminal = (window: Page) => window.getByTestId('shell-terminal');
const sessionList = (window: Page) =>
window.getByRole('listbox', { name: 'Open terminals' });
Expand All @@ -32,9 +32,9 @@ test.describe('Shell terminal', () => {
}) => {
const window = await openProject(electronApp, PROJECT);

// The built-in command terminal is still the default tab.
// The built-in command console is still the default tab.
await expect(
window.getByRole('button', { name: 'TERMINAL', exact: true }),
window.getByRole('button', { name: 'CONSOLE', exact: true }),
).toBeVisible();
await expect(
window.getByPlaceholder('Type a rosetta or dbt command...'),
Expand Down Expand Up @@ -116,7 +116,7 @@ test.describe('Shell terminal', () => {
await newTerminal(window).click();
await expect(sessionList(window).getByRole('option')).toHaveCount(2);

await window.getByRole('button', { name: 'TERMINAL', exact: true }).click();
await window.getByRole('button', { name: 'CONSOLE', exact: true }).click();
await expect(terminal(window)).toHaveCount(0);

// Coming back shows the same terminals instead of starting a new one.
Expand Down
2 changes: 1 addition & 1 deletion src/renderer/components/terminal/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -292,7 +292,7 @@ export const TerminalLayout: React.FC<Props> = ({ children, project }) => {
<Taskbar>
<TaskbarItem onClick={handleRestore}>
<Typography fontSize={13} sx={{ mr: 1 }} fontWeight="bold">
Terminal
Console
</Typography>
<TerminalIcon fontSize="small" />
{isRunning && (
Expand Down
2 changes: 1 addition & 1 deletion src/renderer/components/terminal/panels/ShellPanel.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -388,7 +388,7 @@ const ShellHeaderActions: React.FC<TerminalPanelContext> = ({ project }) => {

export const shellPanel: TerminalPanelDefinition = {
id: 'shell',
label: 'SHELL',
label: 'TERMINAL',
Comment thread
coderabbitai[bot] marked this conversation as resolved.
Resolved
// Never asks for focus on its own; the terminals live outside React, so
// the body can unmount while another tab is shown without losing them.
useState: () => ({ visible: true }),
Expand Down
2 changes: 1 addition & 1 deletion src/renderer/components/terminal/panels/TerminalPanel.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ const TerminalPanelBody: React.FC<TerminalPanelContext> = ({ project }) => (

export const terminalPanel: TerminalPanelDefinition = {
id: 'terminal',
label: 'TERMINAL',
label: 'CONSOLE',
Comment thread
flakronademi marked this conversation as resolved.
Resolved
keepMounted: true,
useState: () => {
// Any CLI command (dbt, rosetta, python run…) surfaces the terminal.
Expand Down
Loading