Bypass sign-in page in createDevApp

The dev app now automatically disables the sign-in page extension,
so plugins under development don't require authentication.

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
Made-with: Cursor
This commit is contained in:
Patrik Oldsberg
2026-03-16 12:05:00 +01:00
parent 0b4ed8550d
commit 63248c824e
4 changed files with 15 additions and 15 deletions
@@ -21,7 +21,6 @@ import {
import { within, waitFor } from '@testing-library/react';
import { mockApis } from '@backstage/test-utils';
import { createDevApp } from './createDevApp';
import { default as appPlugin } from '@backstage/plugin-app';
describe('createDevApp', () => {
afterEach(() => {
@@ -46,16 +45,7 @@ describe('createDevApp', () => {
});
createDevApp({
features: [
appPlugin.withOverrides({
extensions: [
appPlugin
.getExtension('sign-in-page:app')
.override({ disabled: true }),
],
}),
testPlugin,
],
features: [testPlugin],
createAppOptions: {
advanced: {
configLoader: async () => ({ config: mockApis.config() }),
@@ -19,6 +19,7 @@ import {
FrontendFeatureLoader,
} from '@backstage/frontend-plugin-api';
import { createApp, CreateAppOptions } from '@backstage/frontend-defaults';
import appPlugin from '@backstage/plugin-app';
import ReactDOM from 'react-dom/client';
/**
@@ -55,7 +56,16 @@ export interface CreateDevAppOptions {
export function createDevApp(options: CreateDevAppOptions): void {
const app = createApp({
...options.createAppOptions,
features: options.features,
features: [
appPlugin.withOverrides({
extensions: [
appPlugin
.getExtension('sign-in-page:app')
.override({ disabled: true }),
],
}),
...options.features,
],
});
ReactDOM.createRoot(document.getElementById('root')!).render(