-
Notifications
You must be signed in to change notification settings - Fork 2
Add it tests for main.rs and test coverage metrics #28
Conversation
49cd66a
to
52093e0
Compare
Codecov Report
@@ Coverage Diff @@
## master #28 +/- ##
========================================
Coverage ? 69.9%
========================================
Files ? 3
Lines ? 216
Branches ? 0
========================================
Hits ? 151
Misses ? 65
Partials ? 0 |
52093e0
to
5653567
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Couple of questions here! On the whole, nice work! 👏 👍
.travis.yml
Outdated
@@ -1,13 +1,24 @@ | |||
sudo: required |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we need the sudo? I thought this opted into the older version of the Travis container.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah tha'd be because I picked and old tutorial? I'll try removing it
cache: | ||
- cargo | ||
- directories: | ||
- "${HOME}/kcov/" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This doesn't override the usual directories does it? Is it additive?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As we spoke, it is an arbitrary dir cache for kcov
@@ -8,6 +13,13 @@ addons: | |||
packages: | |||
# For building MUSL static builds on Linux. | |||
- musl-tools | |||
- cmake |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are these new packages all for cargo-travis
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes they are.
} | ||
|
||
#[test] | ||
#[should_panic] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice work! These annotations are awesome and never get used enough by people! 👏
server/src/main.rs
Outdated
fn get_repo_with_file_in_root_folder() { | ||
let mut srv = test_server(); | ||
|
||
let query = format!("/repo/{}?file={}&reference={}", "", "README.md", "heads/master"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These are all interpolating static strings into another static string — best to just have one static string in thef first place?
let query = format!("/repo/{}?file={}&reference={}", "", "README.md", "heads/master"); | |
let query = "/repo/?file=README.md&reference=heads/master"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same for all the other format!
calls in here.
dcd4ed1
to
4bfba6c
Compare
- Added a badge, pointing to this branch.
- Unit tests for valid//invalid parameters for run_server - Integration tests with a TestServer for get_repo
4bfba6c
to
d58d145
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice work mate! Amazing job! 👏👏👏
No description provided.