Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Flaky Test [Build&Test / metricbeat-pythonIntegTest / test_output – metricbeat.module.consul.test_consul.ConsulAgentTest_1] #24674

Closed
elasticmachine opened this issue Mar 22, 2021 · 3 comments
Labels
ci-reported Issues that have been automatically reported from the CI flaky-test Unstable or unreliable test cases. needs_team Indicates that the issue/PR needs a Team:* label

Comments

@elasticmachine
Copy link
Collaborator

Flaky Test

Error details

AssertionError: Element counts were not equal: First has 1, Second has 0:  "runtime"

Stack Trace

self = <test_consul.ConsulAgentTest_1 testMethod=test_output>

    @unittest.skipUnless(metricbeat.INTEGRATION_TESTS, "integration test")
    @pytest.mark.tag("integration")
    def test_output(self):
        """
        Consul agent module outputs an event.
        """
        self.render_config_template(modules=[{
            "name": "consul",
            "metricsets": ["agent"],
            "hosts": self.get_hosts(),
            "period": "10s"
        }])
        proc = self.start_beat()
        self.wait_until(lambda: self.output_lines() > 0, max_timeout=30)
        proc.check_kill_and_wait()
        self.assert_no_logged_warnings()
    
        output = self.read_output_json()
        self.assertEqual(len(output), 1)
        evt = output[0]
    
        self.assertCountEqual(self.de_dot(CONSUL_FIELDS), evt.keys())
        consul_agent = evt["consul"]["agent"]
    
        consul_agent.pop("raft", None)
        consul_agent.pop("autopilot", None)
    
        print(consul_agent)
>       self.assertCountEqual(self.de_dot(AGENT_FIELDS), consul_agent.keys())
E       AssertionError: Element counts were not equal:
E       First has 1, Second has 0:  "runtime"

module/consul/test_consul.py:56: AssertionError
@elasticmachine elasticmachine added flaky-test Unstable or unreliable test cases. ci-reported Issues that have been automatically reported from the CI labels Mar 22, 2021
@botelastic botelastic bot added the needs_team Indicates that the issue/PR needs a Team:* label label Mar 22, 2021
@botelastic
Copy link

botelastic bot commented Mar 22, 2021

This issue doesn't have a Team:<team> label.

@ChrsMark
Copy link
Member

@jsoriano isn't this the same with #24603?

@jsoriano
Copy link
Member

@jsoriano isn't this the same with #24603?

Looks like the same, yes. Branch mentioned here didn't include #24663. Closing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ci-reported Issues that have been automatically reported from the CI flaky-test Unstable or unreliable test cases. needs_team Indicates that the issue/PR needs a Team:* label
Projects
None yet
Development

No branches or pull requests

3 participants