22// Licensed under the MIT License.
33
44mod common;
5- use common:: { create_env_variables, resolve_test_path} ;
6- use pet_conda:: environment_locations:: {
7- get_conda_envs_from_environment_txt, get_environments, get_known_conda_locations,
8- } ;
9- use std:: path:: PathBuf ;
105
116#[ cfg( unix) ]
127#[ test]
138fn read_environment_txt ( ) {
9+ use common:: { create_env_variables, resolve_test_path} ;
10+ use pet_conda:: environment_locations:: get_conda_envs_from_environment_txt;
11+ use std:: path:: PathBuf ;
12+
1413 let root = resolve_test_path ( & [ "unix" , "root_empty" ] ) . into ( ) ;
1514 let home = resolve_test_path ( & [ "unix" , "user_home_with_environments_txt" ] ) . into ( ) ;
1615 let env = create_env_variables ( home, root) ;
@@ -53,6 +52,9 @@ fn read_environment_txt() {
5352#[ cfg( unix) ]
5453#[ test]
5554fn non_existent_envrionments_txt ( ) {
55+ use common:: { create_env_variables, resolve_test_path} ;
56+ use pet_conda:: environment_locations:: get_conda_envs_from_environment_txt;
57+
5658 let root = resolve_test_path ( & [ "unix" , "root_empty" ] ) . into ( ) ;
5759 let home = resolve_test_path ( & [ "unix" , "bogus directory" ] ) . into ( ) ;
5860 let env = create_env_variables ( home, root) ;
@@ -65,6 +67,10 @@ fn non_existent_envrionments_txt() {
6567#[ cfg( unix) ]
6668#[ test]
6769fn known_install_locations ( ) {
70+ use common:: { create_env_variables, resolve_test_path} ;
71+ use pet_conda:: environment_locations:: get_known_conda_locations;
72+ use std:: path:: PathBuf ;
73+
6874 let root = resolve_test_path ( & [ "unix" , "root_empty" ] ) . into ( ) ;
6975 let home = resolve_test_path ( & [ "unix" , "user_home" ] ) . into ( ) ;
7076 let env = create_env_variables ( home, root) ;
@@ -102,6 +108,9 @@ fn known_install_locations() {
102108#[ cfg( unix) ]
103109#[ test]
104110fn list_conda_envs_in_install_location ( ) {
111+ use common:: resolve_test_path;
112+ use pet_conda:: environment_locations:: get_environments;
113+
105114 let path = resolve_test_path ( & [ "unix" , "anaconda3-2023.03" ] ) ;
106115
107116 let mut locations = get_environments ( & path) ;
0 commit comments