TransitionWithoutCondition.cc 915 B

123456789101112131415161718192021222324252627
  1. /**
  2. * Copyright (c) 2015 committers of YAKINDU and others.
  3. * All rights reserved. This program and the accompanying materials
  4. * are made available under the terms of the Eclipse Public License v1.0
  5. * which accompanies this distribution, and is available at
  6. * http://www.eclipse.org/legal/epl-v10.html
  7. *
  8. * Contributors:
  9. * committers of YAKINDU - initial API and implementation
  10. */
  11. #include <string>
  12. #include "gtest/gtest.h"
  13. #include "TransitionWithoutCondition.h"
  14. TransitionWithoutCondition handle;
  15. TEST(StatemachineTest, TransitionWithoutConditionTest) {
  16. transitionWithoutCondition_init(&handle);
  17. transitionWithoutCondition_enter(&handle);
  18. EXPECT_TRUE(transitionWithoutCondition_isStateActive(&handle, TransitionWithoutCondition_main_region_A));
  19. transitionWithoutCondition_runCycle(&handle);
  20. EXPECT_TRUE(transitionWithoutCondition_isStateActive(&handle, TransitionWithoutCondition_main_region_B));
  21. }