react-native-navigation的迁移库

RNNSideMenuParserTest.m 831B

1234567891011121314151617181920212223242526272829
  1. #import <XCTest/XCTest.h>
  2. #import "SideMenuOpenGestureModeParser.h"
  3. #import "RCTConvert+SideMenuOpenGestureMode.h"
  4. @interface RNNSideMenuParserTest : XCTestCase
  5. @end
  6. @implementation RNNSideMenuParserTest
  7. - (void)setUp {
  8. [super setUp];
  9. }
  10. - (void)testParseBezelOpenModeReturnDrawerGestureModeBezel {
  11. NSDictionary* dict = @{@"openMode": @"bezel"};
  12. SideMenuOpenMode* openMode = [SideMenuOpenGestureModeParser parse:dict key:@"openMode"];
  13. XCTAssertEqual(openMode.get.integerValue, MMOpenDrawerGestureModeBezelPanningCenterView);
  14. }
  15. - (void)testParseEntireScreenOpenModeReturnDrawerGestureModeAll {
  16. NSDictionary* dict = @{@"openMode": @"entireScreen"};
  17. SideMenuOpenMode* openMode = [SideMenuOpenGestureModeParser parse:dict key:@"openMode"];
  18. XCTAssertEqual(openMode.get.integerValue, MMOpenDrawerGestureModeAll);
  19. }
  20. @end