aboutsummaryrefslogtreecommitdiffstats
path: root/src/github.rs
diff options
context:
space:
mode:
authorTeddy Wing2017-11-12 20:16:54 +0100
committerTeddy Wing2017-11-12 20:16:54 +0100
commitb06e3fe2f1bcf7fa897648ab79e301ccab256ac8 (patch)
tree2c890e557c7b09dc841dc59cda5f5a1a2f3cc1ba /src/github.rs
parent98ff2f8a24f0d32043b4de9b5671a4d882a6e903 (diff)
downloadkipper-b06e3fe2f1bcf7fa897648ab79e301ccab256ac8.tar.bz2
Convert a bunch of `to_string()`s to `to_owned()`
I had used `to_owned()` previously in other projects, but after looking up the difference (again probably), I decided that it seems better to use `to_owned()`. References: https://users.rust-lang.org/t/to-string-vs-to-owned-for-string-literals/1441/6 http://www.lowlevelmanager.com/2016/02/rust-tostring-vs-toowned-for-string.html
Diffstat (limited to 'src/github.rs')
-rw-r--r--src/github.rs12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/github.rs b/src/github.rs
index 91e9266..16f1cde 100644
--- a/src/github.rs
+++ b/src/github.rs
@@ -93,19 +93,19 @@ mod tests {
.create();
let commit_ref = CommitRef {
- owner: "octocat".to_string(),
- repo: "Hello-World".to_string(),
- sha: "6dcb09b5b57875f334f61aebed695e2e4193db5e".to_string(),
- branch: "not-used".to_string(),
+ owner: "octocat".to_owned(),
+ repo: "Hello-World".to_owned(),
+ sha: "6dcb09b5b57875f334f61aebed695e2e4193db5e".to_owned(),
+ branch: "not-used".to_owned(),
};
update_commit_status(
&"token".to_owned(),
&commit_ref,
&CommitStatus::Success,
- "https://jenkins.example.com/job/octocat/3".to_string(),
+ "https://jenkins.example.com/job/octocat/3".to_owned(),
None,
- "continuous-integration/jenkins".to_string()
+ "continuous-integration/jenkins".to_owned()
).expect("Failed to update commit status");
mock.assert();