started refactoring autotype system to use tokenizer

This commit is contained in:
michael starke
2017-11-07 18:24:36 +01:00
parent 3cf44eeb26
commit 46d20228ae
3 changed files with 201 additions and 0 deletions

View File

@@ -0,0 +1,32 @@
//
// MPTestToken.m
// MacPassTests
//
// Created by Michael Starke on 07.11.17.
// Copyright © 2017 HicknHack Software GmbH. All rights reserved.
//
#import <XCTest/XCTest.h>
#import "MPToken.h"
@interface MPTestToken : XCTestCase
@end
@implementation MPTestToken
- (void)setUp {
[super setUp];
}
- (void)tearDown {
[super tearDown];
}
- (void)testTokenizing {
NSArray *tokens =[MPToken tokenizeString:@"{^}{USERNAME}^S+H{SPACE}"];
XCTAssertEqual(7, tokens.count);
}
@end