mirror of
https://github.com/j3ssie/osmedeus.git
synced 2026-09-28 12:34:59 +02:00
feat: update Next.js build assets and add cloud setup E2E tests
- Update Next.js generated chunk hashes and build IDs reflecting latest dashboard build - Update CSS stylesheet references in workflow upload page metadata - Add comprehensive cloud setup E2E test suite (cloud_setup_test.go) with SSH password/key auth, post-command variable expansion, and Ansible integration - Fix API priority levels to include 'medium' priority in test coverage - Add agent-sdk test workflows (minimal, config, codex, multi-agent, session variants) - Update E2E test utilities with runCLIInBase helper for multi-step cloud config tests - Fix stderr/stdout capture in dependencies_target_types_test assertions
This commit is contained in:
@@ -0,0 +1,22 @@
|
||||
kind: module
|
||||
name: test-agent-sdk-codex
|
||||
description: Test agent-sdk step with codex agent
|
||||
tags: test,agent-sdk,codex
|
||||
|
||||
params:
|
||||
- name: target
|
||||
required: true
|
||||
default: example.com
|
||||
|
||||
steps:
|
||||
- name: sdk-codex
|
||||
type: agent-sdk
|
||||
log: "Running Codex SDK agent for {{Target}}"
|
||||
agent: codex
|
||||
sdk_config:
|
||||
sandbox: "danger-full-access"
|
||||
messages:
|
||||
- role: user
|
||||
content: "Explain what {{Target}} is."
|
||||
exports:
|
||||
result: "{{sdk_output}}"
|
||||
@@ -0,0 +1,41 @@
|
||||
kind: module
|
||||
name: test-agent-sdk-config
|
||||
description: Test agent-sdk step with full configuration options
|
||||
tags: test,agent-sdk,config
|
||||
|
||||
params:
|
||||
- name: target
|
||||
required: true
|
||||
default: example.com
|
||||
|
||||
steps:
|
||||
# Agent-SDK with cwd, allowed_paths, and sdk_config
|
||||
- name: sdk-configured
|
||||
type: agent-sdk
|
||||
log: "Running configured SDK agent for {{Target}}"
|
||||
agent: claude-code
|
||||
cwd: "{{Output}}"
|
||||
allowed_paths:
|
||||
- "{{Output}}"
|
||||
- "/tmp"
|
||||
sdk_config:
|
||||
model: "sonnet"
|
||||
max_turns: 10
|
||||
env:
|
||||
CUSTOM_VAR: "hello"
|
||||
TARGET_DOMAIN: "{{Target}}"
|
||||
messages:
|
||||
- role: system
|
||||
content: "You are a security reconnaissance agent. Be concise."
|
||||
- role: user
|
||||
content: "Analyze the target {{Target}} and create a summary file."
|
||||
exports:
|
||||
analysis: "{{sdk_output}}"
|
||||
agent_name: "{{sdk_agent}}"
|
||||
session: "{{sdk_session_id}}"
|
||||
|
||||
# Verify exports from previous step
|
||||
- name: verify-sdk-exports
|
||||
type: bash
|
||||
log: "Verifying SDK exports"
|
||||
command: echo "Agent {{agent_name}} produced output (session {{session}})"
|
||||
@@ -0,0 +1,19 @@
|
||||
kind: module
|
||||
name: test-agent-sdk-minimal
|
||||
description: Minimal agent-sdk step test
|
||||
tags: test,agent-sdk,quick
|
||||
|
||||
params:
|
||||
- name: target
|
||||
required: true
|
||||
default: example.com
|
||||
|
||||
steps:
|
||||
- name: quick-sdk-agent
|
||||
type: agent-sdk
|
||||
agent: claude-code
|
||||
messages:
|
||||
- role: user
|
||||
content: "Run 'echo hello {{Target}}' and tell me the output."
|
||||
exports:
|
||||
result: "{{sdk_output}}"
|
||||
@@ -0,0 +1,54 @@
|
||||
kind: module
|
||||
name: test-agent-sdk-multi
|
||||
description: Test agent-sdk multi-agent strategies (RunFirst / RunAll)
|
||||
tags: test,agent-sdk,multi-agent
|
||||
|
||||
params:
|
||||
- name: target
|
||||
required: true
|
||||
default: example.com
|
||||
|
||||
steps:
|
||||
# RunFirst strategy: race multiple agents, return first success
|
||||
- name: sdk-race
|
||||
type: agent-sdk
|
||||
log: "Racing claude-code vs codex for {{Target}}"
|
||||
cwd: "{{Output}}"
|
||||
sdk_config:
|
||||
strategy: "first"
|
||||
agents:
|
||||
- claude-code
|
||||
- codex
|
||||
messages:
|
||||
- role: user
|
||||
content: "Briefly describe what {{Target}} is in one sentence."
|
||||
exports:
|
||||
race_result: "{{sdk_output}}"
|
||||
race_winner: "{{sdk_agent}}"
|
||||
|
||||
- name: show-race-winner
|
||||
type: bash
|
||||
log: "Race winner"
|
||||
command: echo "Winner {{race_winner}} said - {{race_result}}"
|
||||
|
||||
# RunAll strategy: run all agents concurrently, collect all results
|
||||
- name: sdk-all
|
||||
type: agent-sdk
|
||||
log: "Running all agents for {{Target}}"
|
||||
cwd: "{{Output}}"
|
||||
sdk_config:
|
||||
strategy: "all"
|
||||
agents:
|
||||
- claude-code
|
||||
- codex
|
||||
messages:
|
||||
- role: user
|
||||
content: "Give a one-line security assessment of {{Target}}."
|
||||
exports:
|
||||
all_results: "{{sdk_output}}"
|
||||
all_agents: "{{sdk_agent}}"
|
||||
|
||||
- name: show-all-results
|
||||
type: bash
|
||||
log: "All agent results"
|
||||
command: echo "Agents {{all_agents}} produced results"
|
||||
@@ -0,0 +1,53 @@
|
||||
kind: module
|
||||
name: test-agent-sdk-session
|
||||
description: Test agent-sdk session persistence and resumption (claude-code)
|
||||
tags: test,agent-sdk,session
|
||||
|
||||
params:
|
||||
- name: target
|
||||
required: true
|
||||
default: example.com
|
||||
|
||||
steps:
|
||||
# First turn: start a new session
|
||||
- name: sdk-session-start
|
||||
type: agent-sdk
|
||||
log: "Starting new agent session for {{Target}}"
|
||||
agent: claude-code
|
||||
cwd: "{{Output}}"
|
||||
sdk_config:
|
||||
model: "sonnet"
|
||||
max_turns: 5
|
||||
messages:
|
||||
- role: system
|
||||
content: "You are a security analyst. Remember context across turns."
|
||||
- role: user
|
||||
content: "Remember this target: {{Target}}. Reply with OK and the target name."
|
||||
exports:
|
||||
first_output: "{{sdk_output}}"
|
||||
session_id: "{{sdk_session_id}}"
|
||||
|
||||
- name: show-session
|
||||
type: bash
|
||||
log: "Session established"
|
||||
command: echo "Session {{session_id}} - {{first_output}}"
|
||||
|
||||
# Second turn: resume the previous session
|
||||
- name: sdk-session-resume
|
||||
type: agent-sdk
|
||||
log: "Resuming agent session {{session_id}}"
|
||||
agent: claude-code
|
||||
cwd: "{{Output}}"
|
||||
sdk_config:
|
||||
model: "sonnet"
|
||||
session_resume: "{{session_id}}"
|
||||
messages:
|
||||
- role: user
|
||||
content: "What target did I tell you to remember?"
|
||||
exports:
|
||||
resumed_output: "{{sdk_output}}"
|
||||
|
||||
- name: verify-resume
|
||||
type: bash
|
||||
log: "Session resume result"
|
||||
command: echo "Resumed session said - {{resumed_output}}"
|
||||
@@ -0,0 +1,27 @@
|
||||
kind: module
|
||||
name: test-agent-sdk
|
||||
description: Test agent-sdk step with go-agent-agnostic library
|
||||
tags: test,agent-sdk
|
||||
|
||||
params:
|
||||
- name: target
|
||||
required: true
|
||||
default: example.com
|
||||
|
||||
steps:
|
||||
# Basic agent-sdk step with built-in agent
|
||||
- name: sdk-basic
|
||||
type: agent-sdk
|
||||
log: "Running SDK agent for {{Target}}"
|
||||
agent: claude-code
|
||||
messages:
|
||||
- role: user
|
||||
content: "List the files in the current directory and summarize the results."
|
||||
exports:
|
||||
sdk_result: "{{sdk_output}}"
|
||||
|
||||
# Use SDK output in a subsequent bash step
|
||||
- name: use-sdk-output
|
||||
type: bash
|
||||
log: "Using SDK agent output"
|
||||
command: echo "Agent said - {{sdk_result}}"
|
||||
Reference in New Issue
Block a user