MCP Frontend Testing Server

Integrations

  • Enables serverless deployment on AWS Lambda for scalable test execution and analysis

  • Provides tools for generating and executing Cypress tests, supporting unit, component, and e2e test types for JavaScript/TypeScript code

  • Provides containerization support for deploying the testing server in isolated environments

MCP 프런트엔드 테스트 서버

설명

이 MCP 서버는 다음을 포함하여 프런트엔드 테스트를 위한 도구를 제공합니다.

  • 코드 분석 : JavaScript/TypeScript 코드를 분석하여 적절한 테스트 전략을 결정합니다.
  • 테스트 생성 : Jest와 Cypress에 대한 단위 및 구성 요소 테스트를 생성합니다.
  • 테스트 실행 : Jest와 Cypress를 사용하여 테스트를 실행하고 결과를 반환합니다.
  • 구성 요소 테스트 : React 구성 요소를 테스트하기 위한 도구를 제공합니다.

시작하기

설치

  1. 저장소를 복제합니다: `git clone mcp-frontend-testing`
  2. 프로젝트 디렉토리로 이동합니다: `cd mcp-frontend-testing`
  3. 종속성 설치: `npm install`

서버 실행

HTTP 전송

```배쉬

서버를 빌드하세요

npm 실행 빌드

HTTP 전송으로 서버 시작

npm 실행 시작:http ```

Stdio Transport

```배쉬

서버를 빌드하세요

npm 실행 빌드

Stdio 전송으로 서버 시작

npm 실행 시작:stdio ```

용법

도구

  • analyzeCode : 코드를 분석하고 분석 결과를 반환합니다.
    • 매개변수 :
      • `code` (문자열, 필수): 분석할 소스 코드.
      • `language` (enum, 선택 사항): 코드의 언어(`javascript` | `typescript` | `jsx` | `tsx`, 기본값: `javascript`).
  • generateTest : 소스 코드와 프레임워크를 기반으로 테스트 코드를 생성합니다.
    • 매개변수 :
      • `code` (문자열, 필수): 테스트를 생성할 소스 코드입니다.
      • `framework` (enum, 필수): 테스트 프레임워크(`jest` | `cypress`).
      • `type` (enum, 필수): 테스트 유형(`unit` | `component` | `e2e`).
      • `language` (enum, 선택 사항): 코드의 언어(`javascript` | `typescript` | `jsx` | `tsx`, 기본값: `javascript`).
      • `description` (문자열, 선택 사항): 테스트 사례에 대한 설명입니다.
  • runTest : 테스트를 실행하고 결과를 반환합니다.
    • 매개변수 :
      • `sourceCode` (문자열, 필수): 테스트 중인 소스 코드.
      • `testCode` (문자열, 필수): 실행할 테스트 코드.
      • `framework` (enum, 필수): 테스트 프레임워크(`jest` | `cypress`).
      • `type` (enum, 필수): 테스트 유형(`unit` | `component` | `e2e`).
      • `config` (레코드, 선택 사항): 테스트 실행을 위한 구성 객체.
  • testReactComponent : React 구성 요소에 대한 구성 요소 테스트를 실행합니다.
    • 매개변수 :
      • `componentCode` (문자열, 필수): React 컴포넌트의 소스 코드.
      • `testCode`(문자열, 선택 사항): 구성 요소에 대한 테스트 코드(제공되지 않으면 자동 생성됨).
      • `framework`(열거형, 선택 사항): 테스트 프레임워크(`jest` | `cypress`, 기본값: `jest`).
      • `props`(레코드, 선택 사항): 테스트 중에 구성 요소에 전달할 속성입니다.
      • `autoGenerateTest` (boolean, 선택 사항): 제공되지 않으면 자동으로 테스트 코드를 생성합니다(기본값: `true`).

자원

  • templates : 테스트 템플릿을 제공합니다.
    • URI : `templates://{framework}/{type}`
    • 매개변수 :
      • `framework` (문자열, 필수): 테스트 프레임워크(`jest` | `cypress`).
      • `type` (문자열, 필수): 템플릿 유형(`unit` | `component`).
  • docs : 테스트 프레임워크에 대한 문서를 제공합니다.
    • URI : `docs://{topic}`
    • 매개변수 :
      • `topic` (문자열, 필수): 문서 주제(`jest` | `cypress` | `react-testing-library`).

전개

도커

Docker를 사용하여 서버를 빌드하고 실행합니다.

```bash docker build -t mcp-프런트엔드-테스팅 . docker run -p 3000:3000 mcp-프런트엔드-테스팅 ```

구름

AWS Lambda, Google Cloud Run 또는 Azure Functions와 같은 클라우드 플랫폼에 배포하여 서버리스 또는 컨테이너화된 배포를 구현합니다.


참고 : 이 서버는 LLM이 프런트엔드 테스트 작업을 수행할 수 있도록 MCP 클라이언트와 함께 사용하도록 설계되었습니다.

-
security - not tested
F
license - not found
-
quality - not tested

Jest 및 Cypress 프레임워크에 대한 코드 분석, 테스트 생성, 테스트 실행, React 구성 요소 테스트를 포함한 프런트엔드 테스트를 위한 도구를 제공합니다.

  1. Description
    1. Getting Started
      1. Installation
      2. Running the Server
    2. Build the server
      1. Start the server with HTTP transport
        1. Stdio Transport
      2. Build the server
        1. Start the server with Stdio transport
          1. Usage
          2. Deployment
        ID: x9qtnbbphu