Security: Sync from Public / sync-from-public (push) Has been cancelled
Test: Benchmark Nightly / build (push) Has been cancelled
Test: Benchmark Nightly / Notify Cats on failure (push) Has been cancelled
CI: Python / Checks (push) Has been cancelled
Test: Evals Python / Workflow Comparison Python (push) Has been cancelled
Util: Check Docs URLs / check-docs-urls (push) Has been cancelled
Test: Visual Storybook / Cloudflare Pages (push) Has been cancelled
Test: E2E Performance / build-and-test-performance (push) Has been cancelled
Test: Workflows Nightly / Run Workflow Tests (push) Has been cancelled
Util: Cleanup CI Docker Images / Delete stale CI images (push) Has been cancelled
Test: Benchmark Destroy Env / build (push) Has been cancelled
Util: Update Node Popularity / update-popularity (push) Has been cancelled
Test: E2E Coverage Weekly / Coverage Tests (push) Has been cancelled
41 lines
1.3 KiB
TypeScript
41 lines
1.3 KiB
TypeScript
import { test, expect } from '../../../fixtures/base';
|
|
|
|
test.describe('HTTP Request node', {
|
|
annotation: [
|
|
{ type: 'owner', description: 'NODES' },
|
|
],
|
|
}, () => {
|
|
test.beforeEach(async ({ n8n }) => {
|
|
await n8n.start.fromBlankCanvas();
|
|
});
|
|
|
|
test('should make a request with a URL and receive a response', async ({ n8n }) => {
|
|
await n8n.canvas.addNode('Manual Trigger');
|
|
await n8n.canvas.addNode('HTTP Request', { closeNDV: false });
|
|
|
|
await n8n.ndv.setupHelper.httpRequest({
|
|
url: 'https://catfact.ninja/fact',
|
|
});
|
|
await n8n.ndv.execute();
|
|
|
|
await expect(n8n.ndv.outputPanel.get()).toContainText('fact');
|
|
});
|
|
|
|
test.describe('Credential-only HTTP Request Node variants', () => {
|
|
test('should render a modified HTTP Request Node', async ({ n8n }) => {
|
|
await n8n.canvas.addNode('Manual Trigger');
|
|
await n8n.canvas.addNode('VirusTotal');
|
|
|
|
await expect(n8n.ndv.getNodeNameContainer()).toContainText('VirusTotal HTTP Request');
|
|
await expect(n8n.ndv.getParameterInputField('url')).toHaveValue(
|
|
'https://www.virustotal.com/api/v3/',
|
|
);
|
|
|
|
await expect(n8n.ndv.getParameterInput('authentication')).toBeHidden();
|
|
await expect(n8n.ndv.getParameterInput('nodeCredentialType')).toBeHidden();
|
|
|
|
await expect(n8n.ndv.getCredentialLabel('Credential for VirusTotal')).toBeVisible();
|
|
});
|
|
});
|
|
});
|