Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
59 commits
Select commit Hold shift + click to select a range
68f0024
feat: suppert restsharp 107+
llimllib Jun 16, 2023
5434855
add 'using RestSharp'
llimllib Jun 16, 2023
de74700
update fixtures
llimllib Jun 16, 2023
3efce8e
add write response.content at end
llimllib Jun 16, 2023
db1e012
fix(clojure): don't crash if there's no postData content (#171)
erunion May 25, 2023
3e82744
ci: extend ci testing to run on node 20
erunion May 25, 2023
9209afe
build: 5.1.1 release
erunion May 25, 2023
4f42190
feat: dropping support for node 14
erunion Jun 1, 2023
c20a076
chore(deps): bumping out of date deps
erunion Jun 1, 2023
dd95f04
build: 6.0.0 release
erunion Jun 1, 2023
5e05130
wip
llimllib Jun 16, 2023
fc4a2f5
getting the csharp integration tests running
llimllib Jun 16, 2023
d5b625a
merge main
llimllib Jun 16, 2023
8e31ea0
if NODE_ENV=test, these no longer run
llimllib Jun 17, 2023
27cf00d
better csharp dockerfile
llimllib Jun 17, 2023
38b21cb
the postdata-malformed fixture shouldn't expect a content-type header
llimllib Jun 17, 2023
885cae1
hammering the int tests into shape
llimllib Jun 17, 2023
7629e76
add httpbin
llimllib Jun 17, 2023
039dec7
wip (see below for details)
llimllib Jun 18, 2023
99f917d
updating fixtures for different bin
llimllib Jun 18, 2023
5a98f1e
wip
llimllib Jun 18, 2023
6b742a6
17 of 18 shell tests passing
llimllib Jun 21, 2023
b98dcac
add a reverse proxy so 80 and 443 both go to httpbin
llimllib Jun 22, 2023
c541cfe
remove console
llimllib Jun 22, 2023
bc87f9d
update python output
llimllib Jun 22, 2023
afe1b3d
more dockerfile updating
llimllib Jun 22, 2023
514aa7d
tell requests to use our CA
llimllib Jun 22, 2023
f9760d3
fix python whoopsie
llimllib Jun 22, 2023
422a32a
php tests pass
llimllib Jun 22, 2023
426aca2
tell node to use system ca certs
llimllib Jun 22, 2023
6102793
update node dockerfile
llimllib Jun 22, 2023
bf3b9e0
switch back to mccutchen
llimllib Jun 22, 2023
553776c
Merge branch 'main' into local-httpbin
llimllib Jun 22, 2023
8dc8a7a
format integration_test.sh
llimllib Jun 22, 2023
c67fb05
fix WORKDIR order in node dockerfile
llimllib Jun 22, 2023
ef4d3e0
remove logging
llimllib Jun 22, 2023
0d6670d
now the node tests pass locally
llimllib Jun 22, 2023
87f6f34
try adding a node install
llimllib Jun 22, 2023
06fb08f
Revert "now the node tests pass locally"
llimllib Jun 22, 2023
1f15b5b
ah HA found it
llimllib Jun 22, 2023
32cdc43
remove unnecessary volumes
llimllib Jun 22, 2023
76e77c9
add comment
llimllib Jun 22, 2023
429db5f
Merge branch 'local-httpbin' into csharp-integration-tests
llimllib Jun 22, 2023
7f8aef4
remove merge artifact
llimllib Jun 22, 2023
7e764c2
update csharp dockerfile
llimllib Jun 22, 2023
2cd23eb
integration test fixes + comments
llimllib Jun 22, 2023
0096045
fix csharp content type and add newline at end
llimllib Jun 22, 2023
8dd7349
fix postdata-malformed fixture
llimllib Jun 22, 2023
3d2d38c
add explicit json header
llimllib Jun 22, 2023
a001806
get final tests to pass
llimllib Jun 22, 2023
b7463fc
remove cli arg because I can't figure out how to update the snapshots
llimllib Jun 22, 2023
bd858e6
fix content-type condition
llimllib Jun 22, 2023
4001db3
don't assert content type of no params test
llimllib Jun 22, 2023
4a8ec66
re-add cli arg
llimllib Jun 22, 2023
b036d46
jeez content-types are complicated
llimllib Jun 22, 2023
06c32cf
update snapshot
llimllib Jun 22, 2023
e9454bd
add c# dep on proxy
llimllib Jun 22, 2023
4738de8
un-change package-lock.json
llimllib Jun 23, 2023
ecf20cf
Merge branch 'main' into csharp-integration-tests
llimllib Jun 23, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
node_modules
14 changes: 14 additions & 0 deletions .github/workflows/integration-csharp.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
name: Integrations (C#)
on: [push]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- name: Run tests
run: docker-compose run integration_csharp

- name: Cleanup
if: always()
run: docker-compose down
12 changes: 12 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -78,3 +78,15 @@ services:
- HTTPBIN=true
- INTEGRATION_CLIENT=shell
- NODE_ENV=integration

integration_csharp:
depends_on:
- reverse_proxy
build:
context: .
dockerfile: integrations/csharp.Dockerfile
command: 'npx jest src/integration.test.ts'
environment:
- HTTPBIN=true
- INTEGRATION_CLIENT=csharp
- NODE_ENV=integration
39 changes: 39 additions & 0 deletions integrations/csharp.Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
FROM node:20-alpine3.18 AS node
FROM mcr.microsoft.com/dotnet/sdk:7.0-alpine3.18

COPY integrations/https-cert/rootCA.pem /root/integration-test.pem

# install the integration test certs
RUN apk --no-cache add ca-certificates && \
rm -rf /var/cache/apk/* && \
cp /root/integration-test.pem /usr/local/share/ca-certificates/ && \
update-ca-certificates

# copy node stuff from the node image to the dotnet image. Source for the
# necessary files:
# https://github.com/pyodide/pyodide/blob/1691d347d15a2c211cd49aebe6f15d42dfdf2369/Dockerfile#L105
COPY --from=node /usr/local/bin/node /usr/local/bin/
COPY --from=node /usr/local/lib/node_modules /usr/local/lib/node_modules
RUN ln -s ../lib/node_modules/npm/bin/npm-cli.js /usr/local/bin/npm \
&& ln -s ../lib/node_modules/npm/bin/npx-cli.js /usr/local/bin/npx

WORKDIR /src

# - create a "hello world" project. We will later overwrite Program.cs in that
# folder with our test fixtures to run them
# - install RestSharp into that project
# - make a folder with the appropriate structure to hold the test fixtures
RUN dotnet new console -o IntTestCsharp -f net7.0 && \
cd IntTestCsharp && \
dotnet add package RestSharp && \
mkdir -p /src/IntTestCsharp/src/fixtures/files

# copy the only test fixture into the fixtures dir
ADD src/fixtures/files/hello.txt /src/IntTestCsharp/src/fixtures/files/

# add pacakge.json first so we don't have to `npm install` unless it changes
ADD package.json /src/
RUN npm install

# keep this last so that once this docker image is built it can be used quickly
ADD . /src
4 changes: 1 addition & 3 deletions src/fixtures/requests/multipart-form-data-no-params.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,7 @@ module.exports = {
data: '',
files: {},
form: {},
headers: {
'Content-Type': ['multipart/form-data'],
},
headers: {},
json: null,
method: 'POST',
url: 'https://httpbin.org/anything',
Expand Down
1 change: 1 addition & 0 deletions src/helpers/__snapshots__/utils.test.ts.snap
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ exports[`availableTargets returns all available targets 1`] = `
"title": "Clojure",
},
{
"cli": "dotnet",
"clients": [
{
"description": ".NET Standard HTTP Client",
Expand Down
Loading