File tree Expand file tree Collapse file tree 3 files changed +10
-0
lines changed
postgresql_extensions/tests Expand file tree Collapse file tree 3 files changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -134,6 +134,9 @@ use std::sync::LazyLock;
134134/// The latest PostgreSQL version requirement
135135pub static LATEST : VersionReq = VersionReq :: STAR ;
136136
137+ /// The latest PostgreSQL version 17
138+ pub static V17 : LazyLock < VersionReq > = LazyLock :: new ( || VersionReq :: parse ( "=17" ) . unwrap ( ) ) ;
139+
137140/// The latest PostgreSQL version 16
138141pub static V16 : LazyLock < VersionReq > = LazyLock :: new ( || VersionReq :: parse ( "=16" ) . unwrap ( ) ) ;
139142
@@ -172,6 +175,11 @@ mod tests {
172175 assert_eq ! ( LATEST . to_string( ) , "*" ) ;
173176 }
174177
178+ #[ test]
179+ fn test_version_17 ( ) {
180+ assert_eq ! ( V17 . to_string( ) , "=17" ) ;
181+ }
182+
175183 #[ test]
176184 fn test_version_16 ( ) {
177185 assert_eq ! ( V16 . to_string( ) , "=16" ) ;
Original file line number Diff line number Diff line change @@ -21,6 +21,7 @@ fn test_get_available_extensions() -> anyhow::Result<()> {
2121fn test_lifecycle ( ) -> anyhow:: Result < ( ) > {
2222 let installation_dir = tempfile:: tempdir ( ) ?. path ( ) . to_path_buf ( ) ;
2323 let settings = postgresql_embedded:: Settings {
24+ version : postgresql_embedded:: VersionReq :: parse ( "=16.4.0" ) ?,
2425 installation_dir : installation_dir. clone ( ) ,
2526 ..Default :: default ( )
2627 } ;
Original file line number Diff line number Diff line change @@ -20,6 +20,7 @@ async fn test_get_available_extensions() -> Result<()> {
2020async fn test_lifecycle ( ) -> Result < ( ) > {
2121 let installation_dir = tempfile:: tempdir ( ) ?. path ( ) . to_path_buf ( ) ;
2222 let settings = postgresql_embedded:: Settings {
23+ version : postgresql_embedded:: VersionReq :: parse ( "=16.4.0" ) ?,
2324 installation_dir : installation_dir. clone ( ) ,
2425 ..Default :: default ( )
2526 } ;
You can’t perform that action at this time.
0 commit comments