refactor: rename github:repository:webhook:create to github:webhook
Signed-off-by: @pawelmitka <pawel.mitka@brainly.com>
This commit is contained in:
@@ -39,7 +39,7 @@ import {
|
||||
} from './publish';
|
||||
import {
|
||||
createGithubActionsDispatchAction,
|
||||
createGithubCreateRepositoryWebhookAction,
|
||||
createGithubWebhookAction,
|
||||
} from './github';
|
||||
|
||||
export const createBuiltinActions = (options: {
|
||||
@@ -93,7 +93,7 @@ export const createBuiltinActions = (options: {
|
||||
createGithubActionsDispatchAction({
|
||||
integrations,
|
||||
}),
|
||||
createGithubCreateRepositoryWebhookAction({
|
||||
createGithubWebhookAction({
|
||||
integrations,
|
||||
}),
|
||||
];
|
||||
|
||||
+2
-2
@@ -16,7 +16,7 @@
|
||||
|
||||
jest.mock('@octokit/rest');
|
||||
|
||||
import { createGithubCreateRepositoryWebhookAction } from './githubCreateRepositoryWebhook';
|
||||
import { createGithubWebhookAction } from './githubWebhook';
|
||||
import { ScmIntegrations } from '@backstage/integration';
|
||||
import { ConfigReader } from '@backstage/config';
|
||||
import { getVoidLogger } from '@backstage/backend-common';
|
||||
@@ -33,7 +33,7 @@ describe('github:repository:webhook:create', () => {
|
||||
});
|
||||
|
||||
const integrations = ScmIntegrations.fromConfig(config);
|
||||
const action = createGithubCreateRepositoryWebhookAction({ integrations });
|
||||
const action = createGithubWebhookAction({ integrations });
|
||||
|
||||
const mockContext = {
|
||||
input: {
|
||||
+2
-2
@@ -24,7 +24,7 @@ import { createTemplateAction } from '../../createTemplateAction';
|
||||
|
||||
type ContentType = 'form' | 'json';
|
||||
|
||||
export function createGithubCreateRepositoryWebhookAction(options: {
|
||||
export function createGithubWebhookAction(options: {
|
||||
integrations: ScmIntegrationRegistry;
|
||||
}) {
|
||||
const { integrations } = options;
|
||||
@@ -45,7 +45,7 @@ export function createGithubCreateRepositoryWebhookAction(options: {
|
||||
contentType?: ContentType;
|
||||
insecureSsl?: boolean;
|
||||
}>({
|
||||
id: 'github:repository:webhook:create',
|
||||
id: 'github:webhook',
|
||||
description: 'Creates webhook for a repository on GitHub.',
|
||||
schema: {
|
||||
input: {
|
||||
@@ -15,4 +15,4 @@
|
||||
*/
|
||||
|
||||
export { createGithubActionsDispatchAction } from './githubActionsDispatch';
|
||||
export { createGithubCreateRepositoryWebhookAction } from './githubCreateRepositoryWebhook';
|
||||
export { createGithubWebhookAction } from './githubWebhook';
|
||||
|
||||
Reference in New Issue
Block a user