File tree Expand file tree Collapse file tree 2 files changed +14
-2
lines changed Expand file tree Collapse file tree 2 files changed +14
-2
lines changed Original file line number Diff line number Diff line change @@ -10,18 +10,24 @@ if (getenv('TESTS') !== 'tests/atlas.phpt') { echo "skip Atlas tests not wanted\
1010<?php
1111$ urls = explode ("\n" , file_get_contents ('.evergreen/atlas-uris.txt ' ));
1212
13- $ isMasterCmd = new \MongoDB \Driver \Command (['isMaster ' => 1 ]);
13+ $ command = new \MongoDB \Driver \Command (['ping ' => 1 ]);
1414$ query = new \MongoDB \Driver \Query ([]);
1515
1616foreach ($ urls as $ url ) {
1717 $ url = trim ($ url );
18+
1819 if ($ url == '' ) {
1920 continue ;
2021 }
2122
23+ if (strpos ($ url , '# ' ) === 0 ) {
24+ echo trim (substr ($ url , 1 )), "\n" ;
25+ continue ;
26+ }
27+
2228 try {
2329 $ m = new \MongoDB \Driver \Manager ($ url );
24- $ m ->executeCommand ('admin ' , $ isMasterCmd );
30+ $ m ->executeCommand ('admin ' , $ command );
2531 iterator_to_array ($ m ->executeQuery ('test.test ' , $ query ));
2632 echo "PASS \n" ;
2733 } catch (Exception $ e ) {
@@ -32,16 +38,22 @@ foreach ($urls as $url) {
3238===DONE===
3339<?php exit (0 ); ?>
3440--EXPECTF--
41+ Atlas replica set (3.4)
3542PASS
3643PASS
44+ Atlas sharded cluster (3.4)
3745PASS
3846PASS
47+ Atlas free tier replica set (4.4)
3948PASS
4049PASS
50+ Atlas with only TLSv1.1 enabled (3.4)
4151PASS
4252PASS
53+ Atlas with only TLSv1.2 enabled (3.4)
4354PASS
4455PASS
56+ Atlas with only TLSv1.2 enabled (3.4) and bad credentials
4557FAIL: %s
4658FAIL: %s
4759===DONE===
You can’t perform that action at this time.
0 commit comments