Skip to content

Commit

Permalink
Updated tests
Browse files Browse the repository at this point in the history
  • Loading branch information
nick committed Nov 5, 2024
1 parent 01cf206 commit d88a849
Showing 1 changed file with 26 additions and 51 deletions.
77 changes: 26 additions & 51 deletions test/Manticoresearch/Endpoints/Nodes/VariablesTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,57 +18,32 @@ public function testVariables() {

$keys = array_keys($response);
sort($keys);
// Adding extra try-catch to provide compatibility with previous Manticore versions
try {
$this->assertEquals(
[
'accurate_aggregation',
'auto_optimize',
'autocommit',
'character_set_client',
'character_set_connection',
'collation_connection',
'distinct_precision_threshold',
'grouping_in_utc',
'last_insert_id',
'log_level',
'max_allowed_packet',
'optimize_cutoff',
'pseudo_sharding',
'query_log_format',
'secondary_indexes',
'session_read_only',
'thread_stack',
'threads_ex',
'threads_ex_effective',
'timezone',
], $keys
);
} catch (\PHPUnit\Framework\ExpectationFailedException $e) {
$this->assertEquals(
[
'accurate_aggregation',
'auto_optimize',
'autocommit',
'character_set_client',
'character_set_connection',
'collation_connection',
'distinct_precision_threshold',
'grouping_in_utc',
'last_insert_id',
'log_level',
'max_allowed_packet',
'optimize_cutoff',
'pseudo_sharding',
'query_log_format',
'secondary_indexes',
'session_read_only',
'thread_stack',
'threads_ex',
'threads_ex_effective',
], $keys
);
}
$this->assertEquals(
[
'accurate_aggregation',
'auto_optimize',
'autocommit',
'character_set_client',
'character_set_connection',
'cluster_user',
'collation_connection',
'distinct_precision_threshold',
'grouping_in_utc',
'last_insert_id',
'log_level',
'max_allowed_packet',
'optimize_cutoff',
'pseudo_sharding',
'query_log_format',
'secondary_indexes',
'session_read_only',
'thread_stack',
'threads_ex',
'threads_ex_effective',
'timezone',
'user',
], $keys
);
}

public function testVariablesWithPattern() {
Expand Down

0 comments on commit d88a849

Please sign in to comment.