1
0
mirror of https://github.com/actix/actix-extras.git synced 2024-11-28 01:32:57 +01:00

content-encoding; try cargo tarpaulin

This commit is contained in:
Nikolay Kim 2017-12-02 11:41:20 -08:00
parent 0fc01c48d1
commit d0b9d9c1d6
4 changed files with 32 additions and 17 deletions

View File

@ -49,18 +49,21 @@ after_success:
- | - |
if [[ "$TRAVIS_OS_NAME" == "linux" && "$TRAVIS_RUST_VERSION" == "stable" ]]; then if [[ "$TRAVIS_OS_NAME" == "linux" && "$TRAVIS_RUST_VERSION" == "stable" ]]; then
wget https://github.com/SimonKagstrom/kcov/archive/master.tar.gz && bash <(curl https://raw.githubusercontent.com/xd009642/tarpaulin/master/travis-install.sh)
tar xzf master.tar.gz && cargo tarpaulin --out Xml
cd kcov-master && bash <(curl -s https://codecov.io/bash)
mkdir build && #wget https://github.com/SimonKagstrom/kcov/archive/master.tar.gz &&
cd build && #tar xzf master.tar.gz &&
cmake .. && #cd kcov-master &&
make && #mkdir build &&
make install DESTDIR=../../kcov-build && #cd build &&
cd ../.. && #cmake .. &&
rm -rf kcov-master && #make &&
for file in target/debug/actix_web-*[^\.d]; do mkdir -p "target/cov/$(basename $file)"; ./kcov-build/usr/local/bin/kcov --exclude-pattern=/.cargo,/usr/lib --verify "target/cov/$(basename $file)" "$file"; done && #make install DESTDIR=../../kcov-build &&
for file in target/debug/test_*[^\.d]; do mkdir -p "target/cov/$(basename $file)"; ./kcov-build/usr/local/bin/kcov --exclude-pattern=/.cargo,/usr/lib --verify "target/cov/$(basename $file)" "$file"; done && #cd ../.. &&
bash <(curl -s https://codecov.io/bash) && #rm -rf kcov-master &&
#for file in target/debug/actix_web-*[^\.d]; do mkdir -p "target/cov/$(basename $file)"; ./kcov-build/usr/local/bin/kcov --exclude-pattern=/.cargo,/usr/lib --verify "target/cov/$(basename $file)" "$file"; done &&
#for file in target/debug/test_*[^\.d]; do mkdir -p "target/cov/$(basename $file)"; ./kcov-build/usr/local/bin/kcov --exclude-pattern=/.cargo,/usr/lib --verify "target/cov/$(basename $file)" "$file"; done &&
#bash <(curl -s https://codecov.io/bash) &&
echo "Uploaded code coverage" echo "Uploaded code coverage"
fi fi

View File

@ -6,8 +6,7 @@
- [Handler](./qs_4.md) - [Handler](./qs_4.md)
- [Resources and Routes](./qs_5.md) - [Resources and Routes](./qs_5.md)
- [Application state](./qs_6.md) - [Application state](./qs_6.md)
- [Request](./qs_7.md) - [Request & Response](./qs_7.md)
- [Response](./qs_8.md)
- [WebSockets](./qs_9.md) - [WebSockets](./qs_9.md)
- [User sessions](./qs_10.md) - [User sessions](./qs_10.md)
- [Logging](./qs_11.md) - [Logging](./qs_11.md)

View File

@ -1 +1,15 @@
# Request # HttpRequest & HttpResponse
## Content encoding
Actix automatically *compress*/*decompress* payload.
Following encodings are supported:
* Brotli
* Gzip
* Deflate
* Identity
If request headers contains `Content-Encoding` header, request payload get decompressed
according to header value. Multiple codecs are not supported, i.e: `Content-Encoding: br, gzip`.

View File

@ -1 +0,0 @@
# Response