Apache Mesos
kill_policy_test_helper.hpp
Go to the documentation of this file.
1 // Licensed to the Apache Software Foundation (ASF) under one
2 // or more contributor license agreements. See the NOTICE file
3 // distributed with this work for additional information
4 // regarding copyright ownership. The ASF licenses this file
5 // to you under the Apache License, Version 2.0 (the
6 // "License"); you may not use this file except in compliance
7 // with the License. You may obtain a copy of the License at
8 //
9 // http://www.apache.org/licenses/LICENSE-2.0
10 //
11 // Unless required by applicable law or agreed to in writing, software
12 // distributed under the License is distributed on an "AS IS" BASIS,
13 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 // See the License for the specific language governing permissions and
15 // limitations under the License.
16 
17 #ifndef __KILL_POLICY_TEST_HELPER_HPP__
18 #define __KILL_POLICY_TEST_HELPER_HPP__
19 
20 #include <cstdint>
21 
22 #include <stout/flags.hpp>
23 #include <stout/subcommand.hpp>
24 
25 namespace mesos {
26 namespace internal {
27 namespace tests {
28 
30 {
31 public:
32  static const char NAME[];
33 
34  struct Flags : public virtual flags::FlagsBase
35  {
36  Flags();
37 
38  uint16_t sleep_duration;
39  };
40 
42 
44 
45 protected:
46  int execute() override;
47  flags::FlagsBase* getFlags() override { return &flags; }
48 };
49 
50 } // namespace tests {
51 } // namespace internal {
52 } // namespace mesos {
53 
54 #endif // __KILL_POLICY_TEST_HELPER_HPP__
Flags flags
Definition: kill_policy_test_helper.hpp:43
static const char NAME[]
Definition: kill_policy_test_helper.hpp:32
Definition: kill_policy_test_helper.hpp:29
Definition: subcommand.hpp:41
Definition: kill_policy_test_helper.hpp:34
Definition: flags.hpp:44
Definition: agent.hpp:25
KillPolicyTestHelper()
Definition: kill_policy_test_helper.hpp:41
uint16_t sleep_duration
Definition: kill_policy_test_helper.hpp:38
Definition: attributes.hpp:24
flags::FlagsBase * getFlags() override
Definition: kill_policy_test_helper.hpp:47