File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed
astra-db-java/src/test/java/com/datastax/astra/test/integration Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -83,6 +83,10 @@ void shouldCreateNamespaceDefault() throws InterruptedException {
83
83
84
84
// When
85
85
getDatabaseAdmin ().createNamespaceAsync ("ns2" ).thenAccept (dan -> assertThat (dan ).isNotNull ());
86
+ while (!getDatabaseAdmin ().namespaceExists ("ns2" )) {
87
+ log .warn ("Waiting for namespace 'ns2' to be created and db to be active" );
88
+ Thread .sleep (1000 );
89
+ }
86
90
87
91
// Surface
88
92
final DatabaseAdmin dbAdmin2 = getDatabaseAdmin ();
@@ -98,11 +102,11 @@ void shouldCreateNamespaceDefault() throws InterruptedException {
98
102
@ Order (5 )
99
103
void shouldDropNamespace () throws InterruptedException {
100
104
assertThat ( getDatabaseAdmin ().listNamespaceNames ())
101
- .as ("Check if 'ns2 ' is present in the namespace names" )
105
+ .as ("Check if 'nsx ' is present in the namespace names" )
102
106
.anyMatch ("nsx" ::equals );
103
107
assertThat ( getDatabaseAdmin ().namespaceExists ("nsx" )).isTrue ();
104
108
Database ns2 = getDatabaseAdmin ().getDatabase ("nsx" );
105
- assertThat ("nsx" ).isNotNull ();
109
+ assertThat (ns2 ).isNotNull ();
106
110
ns2 .drop ();
107
111
while (getDatabaseAdmin ().namespaceExists ("nsx" )) {
108
112
log .warn ("Waiting for namespace 'nsx' to be delete" );
You can’t perform that action at this time.
0 commit comments