routes.test.js — astro Source File
Architecture documentation for routes.test.js, a javascript file in the astro codebase. 5 imports, 0 dependents.
Entity Profile
Dependency Diagram
graph LR fd78463f_09a0_d4aa_9bfe_98fa7800cca6["routes.test.js"] 4b1e6526_afae_1cc3_9eb4_67fe4c476b26["test-utils.js"] fd78463f_09a0_d4aa_9bfe_98fa7800cca6 --> 4b1e6526_afae_1cc3_9eb4_67fe4c476b26 5ab044f2_ed09_99b6_2b30_c55f0f9a239c["loadFixture"] fd78463f_09a0_d4aa_9bfe_98fa7800cca6 --> 5ab044f2_ed09_99b6_2b30_c55f0f9a239c b2ff3d1c_3baf_6707_d502_0f4b2a220a11["readXML"] fd78463f_09a0_d4aa_9bfe_98fa7800cca6 --> b2ff3d1c_3baf_6707_d502_0f4b2a220a11 e1e2fac7_5a95_7a88_cb1e_0a3b91c4e607["strict"] fd78463f_09a0_d4aa_9bfe_98fa7800cca6 --> e1e2fac7_5a95_7a88_cb1e_0a3b91c4e607 6b0635f9_51ea_77aa_767b_7857878e98a6["node:test"] fd78463f_09a0_d4aa_9bfe_98fa7800cca6 --> 6b0635f9_51ea_77aa_767b_7857878e98a6 style fd78463f_09a0_d4aa_9bfe_98fa7800cca6 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
import assert from 'node:assert/strict';
import { before, describe, it } from 'node:test';
import { loadFixture, readXML } from './test-utils.js';
describe('routes', () => {
/** @type {import('./test-utils.js').Fixture} */
let fixture;
/** @type {string[]} */
let urls;
before(async () => {
fixture = await loadFixture({
root: './fixtures/static/',
});
await fixture.build();
const data = await readXML(fixture.readFile('/sitemap-0.xml'));
urls = data.urlset.url.map((url) => url.loc[0]);
});
it('does not include endpoints', async () => {
assert.equal(urls.includes('http://example.com/endpoint.json'), false);
});
it('does not include redirects', async () => {
assert.equal(urls.includes('http://example.com/redirect'), false);
});
});
Domain
Dependencies
- loadFixture
- node:test
- readXML
- strict
- test-utils.js
Source
Frequently Asked Questions
What does routes.test.js do?
routes.test.js is a source file in the astro codebase, written in javascript. It belongs to the CoreAstro domain.
What does routes.test.js depend on?
routes.test.js imports 5 module(s): loadFixture, node:test, readXML, strict, test-utils.js.
Where is routes.test.js in the architecture?
routes.test.js is located at packages/integrations/sitemap/test/routes.test.js (domain: CoreAstro, directory: packages/integrations/sitemap/test).
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free