Source
'expected_error' => 'Cannot evaluate expression: invalid string values of bucket for function at "histogram_quantile(0.8,0.1,last(//rate[0.1]),"Inf2",last(//rate[Inf2]))"',
<?php
/*
** Copyright (C) 2001-2025 Zabbix SIA
**
** This program is free software: you can redistribute it and/or modify it under the terms of
** the GNU Affero General Public License as published by the Free Software Foundation, version 3.
**
** This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
** without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
** See the GNU Affero General Public License for more details.
**
** You should have received a copy of the GNU Affero General Public License along with this program.
** If not, see <https://www.gnu.org/licenses/>.
**/
require_once dirname(__FILE__).'/../include/CIntegrationTest.php';
/**
* Test suite for items state change verification.
*
* @required-components server
* @hosts test_host
* @backup history
*/
class testItemRate extends CIntegrationTest {
const HOST_NAME = 'test_host';
const WAIT_TIME = 3;
private static $hostid;
private static $interfaceid;
private static $values;
private static $items = [
[
'key' => 'kuber_metric[0.1]',
'value_type' => ITEM_VALUE_TYPE_FLOAT,
'start' => 0,
'step' => 1,
'count' => 120
],
[
'key' => 'kuber_metric[0.3]',
'value_type' => ITEM_VALUE_TYPE_FLOAT,
'start' => 0,
'step' => 2,
'count' => 120
],
[
'key' => 'kuber_metric[0.5]',
'value_type' => ITEM_VALUE_TYPE_FLOAT,
'start' => 0,
'step' => 4,
'count' => 120
],
[
'key' => 'kuber_metric[0.7]',
'value_type' => ITEM_VALUE_TYPE_FLOAT,
'start' => 0,
'step' => 8,
'count' => 120
],
[
'key' => 'kuber_metric[0.9]',
'value_type' => ITEM_VALUE_TYPE_FLOAT,
'start' => 0,
'step' => 16,
'count' => 120
],
[
'key' => 'kuber_metric[+Inf]',
'value_type' => ITEM_VALUE_TYPE_FLOAT,
'start' => 0,
'step' => 32,
'count' => 120
],
[
'key' => 'kuber_metric[Inf2]',
'value_type' => ITEM_VALUE_TYPE_FLOAT,
'start' => 0,
'step' => 32,
'count' => 120
],
[
'key' => 'kuber_metric2[promparam,0.1]',
'value_type' => ITEM_VALUE_TYPE_FLOAT,
'start' => 0,
'step' => 1,
'count' => 120
],
[