File tree Expand file tree Collapse file tree 1 file changed +4
-5
lines changed Expand file tree Collapse file tree 1 file changed +4
-5
lines changed Original file line number Diff line number Diff line change
1
+ #![ feature( test) ]
1
2
extern crate test;
2
3
extern crate postgres;
3
4
4
- use test:: Bencher ;
5
-
6
- use postgres:: { Connection , SslMode } ;
5
+ use postgres:: { Connection , TlsMode } ;
7
6
8
7
#[ bench]
9
8
fn bench_naiive_execute ( b : & mut test:: Bencher ) {
10
- let conn = Connection :: connect ( "postgres://postgres@localhost" , & SslMode :: None ) . unwrap ( ) ;
9
+ let conn = Connection :: connect ( "postgres://postgres@localhost" , TlsMode :: None ) . unwrap ( ) ;
11
10
conn. execute ( "CREATE TEMPORARY TABLE foo (id INT)" , & [ ] ) . unwrap ( ) ;
12
11
13
12
b. iter ( || {
@@ -20,7 +19,7 @@ fn bench_naiive_execute(b: &mut test::Bencher) {
20
19
21
20
#[ bench]
22
21
fn bench_execute ( b : & mut test:: Bencher ) {
23
- let conn = Connection :: connect ( "postgres://postgres@localhost" , & SslMode :: None ) . unwrap ( ) ;
22
+ let conn = Connection :: connect ( "postgres://postgres@localhost" , TlsMode :: None ) . unwrap ( ) ;
24
23
conn. execute ( "CREATE TEMPORARY TABLE foo (id INT)" , & [ ] ) . unwrap ( ) ;
25
24
26
25
b. iter ( || {
You can’t perform that action at this time.
0 commit comments