Skip to content

Commit

Permalink
fix(benches): adjust to missing set_ssl_verifier
Browse files Browse the repository at this point in the history
In 53bba6e , ssl usage was improved. The existing benchmark
implementation wasn't adjusted though.

This commit fixes the client benchmark to work with the latest nightly
rust and instructs travis to try compile the benchmarks
when rustc nightly is used. This should prevent such kind of breakage
in future.
  • Loading branch information
Byron committed Jun 26, 2015
1 parent 5bf91f0 commit eb38a11
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
1 change: 1 addition & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ cache:
script:
- cargo build --verbose $FEATURES
- cargo test --verbose $FEATURES
- '[ $TRAVIS_RUST_VERSION = nightly ] && cargo bench --no-run || :'

addons:
apt:
Expand Down
8 changes: 2 additions & 6 deletions benches/client.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#![deny(warnings)]
#![feature(collections, test)]
#![feature(vec_push_all, test)]
extern crate hyper;

extern crate test;
Expand All @@ -8,7 +8,7 @@ use std::fmt;
use std::io::{self, Read, Write, Cursor};
use std::net::SocketAddr;

use hyper::net::{self, ContextVerifier};
use hyper::net;

static README: &'static [u8] = include_bytes!("../README.md");

Expand Down Expand Up @@ -82,10 +82,6 @@ impl net::NetworkConnector for MockConnector {
fn connect(&self, _: &str, _: u16, _: &str) -> hyper::Result<MockStream> {
Ok(MockStream::new())
}

fn set_ssl_verifier(&mut self, _verifier: ContextVerifier) {
// pass
}
}

#[bench]
Expand Down

0 comments on commit eb38a11

Please sign in to comment.