forked from microsoft/chat-copilot
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Copy static files in proper folder (microsoft#678)
### Motivation and Context We want static files to be properly served by the backend ### Description - Copy folder contents of "build" instead of folder itself - Add int test to check for presence of static files ### Contribution Checklist - [ ] The code builds clean without any errors or warnings - [ ] The PR follows the [Contribution Guidelines](https://github.com/microsoft/chat-copilot/blob/main/CONTRIBUTING.md) and the [pre-submission formatting script](https://github.com/microsoft/chat-copilot/blob/main/CONTRIBUTING.md#development-scripts) raises no violations - [ ] All unit tests pass, and I have added new tests where possible - [ ] I didn't break anyone 😄
- Loading branch information
Showing
3 changed files
with
23 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
// Copyright (c) Microsoft. All rights reserved. | ||
|
||
using System.Net.Http; | ||
using Xunit; | ||
|
||
namespace ChatCopilotIntegrationTests; | ||
|
||
public class StaticFiles : ChatCopilotIntegrationTest | ||
{ | ||
[Fact] | ||
public async void GetStaticFiles() | ||
{ | ||
HttpResponseMessage response = await this._httpClient.GetAsync("index.html"); | ||
response.EnsureSuccessStatusCode(); | ||
Assert.True(response.Content.Headers.ContentLength > 1); | ||
|
||
response = await this._httpClient.GetAsync("favicon.ico"); | ||
response.EnsureSuccessStatusCode(); | ||
Assert.True(response.Content.Headers.ContentLength > 1); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters