chore(html): allow serving from a subfolder (#9653)
This commit is contained in:
parent
5426e24248
commit
b3b5497578
|
|
@ -89,7 +89,7 @@ const TestFileSummaryView: React.FC<{
|
||||||
{file.fileName}
|
{file.fileName}
|
||||||
<StatsView stats={file.stats}></StatsView>
|
<StatsView stats={file.stats}></StatsView>
|
||||||
</span>}>
|
</span>}>
|
||||||
{file.tests.map((test, i) => <Link key={`test-${i}`} href={`/?testId=${test.testId}`}>
|
{file.tests.map((test, i) => <Link key={`test-${i}`} href={`?testId=${test.testId}`}>
|
||||||
<div className={'test-summary outcome-' + test.outcome}>
|
<div className={'test-summary outcome-' + test.outcome}>
|
||||||
<span style={{ float: 'right' }}>{msToString(test.duration)}</span>
|
<span style={{ float: 'right' }}>{msToString(test.duration)}</span>
|
||||||
{statusIcon(test.outcome)}
|
{statusIcon(test.outcome)}
|
||||||
|
|
@ -113,7 +113,7 @@ const TestCaseView: React.FC<{
|
||||||
const fileId = testId.split('-')[0];
|
const fileId = testId.split('-')[0];
|
||||||
if (!fileId)
|
if (!fileId)
|
||||||
return;
|
return;
|
||||||
const result = await fetch(`/data/${fileId}.json`, { cache: 'no-cache' });
|
const result = await fetch(`data/${fileId}.json`, { cache: 'no-cache' });
|
||||||
const file = await result.json() as TestFile;
|
const file = await result.json() as TestFile;
|
||||||
for (const t of file.tests) {
|
for (const t of file.tests) {
|
||||||
if (t.testId === testId) {
|
if (t.testId === testId) {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue