mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-01-17 11:08:06 +00:00
logs: use new liblinphone logs API
This commit is contained in:
parent
cb62b4cf68
commit
a3552fba39
21 changed files with 139 additions and 179 deletions
|
|
@ -573,10 +573,10 @@ static void dump_section(const char *section, void *data) {
|
|||
|
||||
#pragma mark - Logs Functions handlers
|
||||
static void linphone_iphone_log_user_info(struct _LinphoneCore *lc, const char *message) {
|
||||
linphone_iphone_log_handler(ORTP_MESSAGE, message, NULL);
|
||||
linphone_iphone_log_handler(NULL, ORTP_MESSAGE, message, NULL);
|
||||
}
|
||||
static void linphone_iphone_log_user_warning(struct _LinphoneCore *lc, const char *message) {
|
||||
linphone_iphone_log_handler(ORTP_WARNING, message, NULL);
|
||||
linphone_iphone_log_handler(NULL, ORTP_WARNING, message, NULL);
|
||||
}
|
||||
|
||||
#pragma mark - Display Status Functions
|
||||
|
|
@ -1439,7 +1439,6 @@ static BOOL libStarted = FALSE;
|
|||
LOGI(@"linphonecore is already created");
|
||||
return;
|
||||
}
|
||||
linphone_core_set_log_collection_path([[LinphoneManager cacheDirectory] UTF8String]);
|
||||
[Log enableLogs:[self lpConfigBoolForKey:@"debugenable_preference"]];
|
||||
connectivity = none;
|
||||
|
||||
|
|
|
|||
|
|
@ -19,13 +19,12 @@
|
|||
|
||||
#import "LinphoneManager.h"
|
||||
|
||||
#define APP_LVL 1 << 7
|
||||
#define LOGV(level, ...) [Log log:APP_LVL & level file:__FILE__ line:__LINE__ format:__VA_ARGS__]
|
||||
#define LOGD(...) LOGV(APP_LVL | ORTP_DEBUG, __VA_ARGS__)
|
||||
#define LOGI(...) LOGV(APP_LVL | ORTP_MESSAGE, __VA_ARGS__)
|
||||
#define LOGW(...) LOGV(APP_LVL | ORTP_WARNING, __VA_ARGS__)
|
||||
#define LOGE(...) LOGV(APP_LVL | ORTP_ERROR, __VA_ARGS__)
|
||||
#define LOGF(...) LOGV(APP_LVL | ORTP_FATAL, __VA_ARGS__)
|
||||
#define LOGV(level, ...) [Log log:level file:__FILE__ line:__LINE__ format:__VA_ARGS__]
|
||||
#define LOGD(...) LOGV(ORTP_DEBUG, __VA_ARGS__)
|
||||
#define LOGI(...) LOGV(ORTP_MESSAGE, __VA_ARGS__)
|
||||
#define LOGW(...) LOGV(ORTP_WARNING, __VA_ARGS__)
|
||||
#define LOGE(...) LOGV(ORTP_ERROR, __VA_ARGS__)
|
||||
#define LOGF(...) LOGV(ORTP_FATAL, __VA_ARGS__)
|
||||
|
||||
@interface Log : NSObject {
|
||||
}
|
||||
|
|
@ -33,5 +32,5 @@
|
|||
+ (void)log:(OrtpLogLevel)severity file:(const char *)file line:(int)line format:(NSString *)format, ...;
|
||||
+ (void)enableLogs:(BOOL)enabled;
|
||||
|
||||
void linphone_iphone_log_handler(int lev, const char *fmt, va_list args);
|
||||
void linphone_iphone_log_handler(const char *domain, OrtpLogLevel lev, const char *fmt, va_list args);
|
||||
@end
|
||||
|
|
@ -21,42 +21,45 @@
|
|||
|
||||
@implementation Log
|
||||
|
||||
#define FILESIZE 17
|
||||
#define DOMAIN_SIZE 3
|
||||
|
||||
+ (NSString *)cacheDirectory {
|
||||
NSArray *paths = NSSearchPathForDirectoriesInDomains(NSCachesDirectory, NSUserDomainMask, YES);
|
||||
NSString *cachePath = [paths objectAtIndex:0];
|
||||
BOOL isDir = NO;
|
||||
NSError *error;
|
||||
// cache directory must be created if not existing
|
||||
if (![[NSFileManager defaultManager] fileExistsAtPath:cachePath isDirectory:&isDir] && isDir == NO) {
|
||||
[[NSFileManager defaultManager] createDirectoryAtPath:cachePath
|
||||
withIntermediateDirectories:NO
|
||||
attributes:nil
|
||||
error:&error];
|
||||
}
|
||||
return cachePath;
|
||||
}
|
||||
|
||||
+ (void)log:(OrtpLogLevel)severity file:(const char *)file line:(int)line format:(NSString *)format, ... {
|
||||
va_list args;
|
||||
va_start(args, format);
|
||||
NSString *str = [[NSString alloc] initWithFormat:format arguments:args];
|
||||
const char *utf8str = [str cStringUsingEncoding:NSString.defaultCStringEncoding];
|
||||
int filesize = 20;
|
||||
const char *filename = strchr(file, '/') ? strrchr(file, '/') + 1 : file;
|
||||
|
||||
char levelC = 'U'; // undefined
|
||||
if ((severity & ORTP_FATAL) != 0) {
|
||||
levelC = 'F';
|
||||
} else if ((severity & ORTP_ERROR) != 0) {
|
||||
levelC = 'E';
|
||||
} else if ((severity & ORTP_WARNING) != 0) {
|
||||
levelC = 'W';
|
||||
} else if ((severity & ORTP_MESSAGE) != 0) {
|
||||
levelC = 'I';
|
||||
} else if ((severity & ORTP_DEBUG) != 0) {
|
||||
levelC = 'D';
|
||||
}
|
||||
|
||||
if ((severity & ORTP_DEBUG) != 0) {
|
||||
// lol: ortp_debug(XXX) can be disabled at compile time, but ortp_log(ORTP_DEBUG, xxx) will always be valid even
|
||||
// not in debug build...
|
||||
ortp_debug("%c %*s:%3d - %s", levelC, filesize, filename + MAX((int)strlen(filename) - filesize, 0), line,
|
||||
utf8str);
|
||||
ortp_debug("%*s:%-4d/%s", FILESIZE, filename + MAX((int)strlen(filename) - FILESIZE, 0), line, utf8str);
|
||||
} else {
|
||||
// we want application logs to be always enabled (except debug ones) so use | ORTP_ERROR extra mask
|
||||
ortp_log(severity | ORTP_ERROR, "%c %*s:%3d - %s", levelC, filesize,
|
||||
filename + MAX((int)strlen(filename) - filesize, 0), line, utf8str);
|
||||
ortp_log(severity, "%*s:%-4d/%s", FILESIZE, filename + MAX((int)strlen(filename) - FILESIZE, 0), line, utf8str);
|
||||
}
|
||||
va_end(args);
|
||||
}
|
||||
|
||||
+ (void)enableLogs:(BOOL)enabled {
|
||||
linphone_core_enable_logs_with_cb((OrtpLogFunc)linphone_iphone_log_handler);
|
||||
linphone_core_set_log_collection_path([self cacheDirectory].UTF8String);
|
||||
linphone_core_enable_log_collection(enabled);
|
||||
linphone_core_enable_logs_with_cb(linphone_iphone_log_handler);
|
||||
if (enabled) {
|
||||
NSLog(@"Enabling debug logs");
|
||||
linphone_core_set_log_level(ORTP_DEBUG);
|
||||
|
|
@ -64,30 +67,33 @@
|
|||
NSLog(@"Disabling debug logs");
|
||||
linphone_core_set_log_level(ORTP_ERROR);
|
||||
}
|
||||
linphone_core_enable_log_collection(enabled);
|
||||
ortp_set_log_level_mask("ios", ORTP_DEBUG | ORTP_MESSAGE | ORTP_WARNING | ORTP_ERROR | ORTP_FATAL);
|
||||
}
|
||||
|
||||
#pragma mark - Logs Functions callbacks
|
||||
|
||||
void linphone_iphone_log_handler(int lev, const char *fmt, va_list args) {
|
||||
void linphone_iphone_log_handler(const char *domain, OrtpLogLevel lev, const char *fmt, va_list args) {
|
||||
NSString *format = [[NSString alloc] initWithUTF8String:fmt];
|
||||
NSString *formatedString = [[NSString alloc] initWithFormat:format arguments:args];
|
||||
NSString *lvl = @"";
|
||||
if ((lev & APP_LVL) == 0) {
|
||||
if ((lev & ORTP_FATAL) != 0) {
|
||||
lvl = @"F ";
|
||||
} else if ((lev & ORTP_ERROR) != 0) {
|
||||
lvl = @"E ";
|
||||
} else if ((lev & ORTP_WARNING) != 0) {
|
||||
lvl = @"W ";
|
||||
} else if ((lev & ORTP_MESSAGE) != 0) {
|
||||
lvl = @"I ";
|
||||
} else if (((lev & ORTP_TRACE) != 0) || ((lev & ORTP_DEBUG) != 0)) {
|
||||
lvl = @"D ";
|
||||
}
|
||||
if ((lev & ORTP_FATAL) != 0) {
|
||||
lvl = @"F";
|
||||
} else if ((lev & ORTP_ERROR) != 0) {
|
||||
lvl = @"E";
|
||||
} else if ((lev & ORTP_WARNING) != 0) {
|
||||
lvl = @"W";
|
||||
} else if ((lev & ORTP_MESSAGE) != 0) {
|
||||
lvl = @"I";
|
||||
} else if (((lev & ORTP_TRACE) != 0) || ((lev & ORTP_DEBUG) != 0)) {
|
||||
lvl = @"D";
|
||||
}
|
||||
if (!domain)
|
||||
domain = "liblinphone";
|
||||
// since \r are interpreted like \n, avoid double new lines when logging network packets (belle-sip)
|
||||
NSLog(@"%@%@", lvl, [formatedString stringByReplacingOccurrencesOfString:@"\r\n" withString:@"\n"]);
|
||||
// output format is like: I/ios/some logs. We truncate domain to **exactly** DOMAIN_SIZE characters to have
|
||||
// fixed-length aligned logs
|
||||
NSLog(@"%@/%*.*s/%@", lvl, DOMAIN_SIZE, DOMAIN_SIZE, domain,
|
||||
[formatedString stringByReplacingOccurrencesOfString:@"\r\n" withString:@"\n"]);
|
||||
}
|
||||
|
||||
@end
|
||||
|
|
|
|||
BIN
Default-568h@2x.png
Normal file
BIN
Default-568h@2x.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 18 KiB |
|
|
@ -1,7 +1,8 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="7706" systemVersion="14D136" targetRuntime="iOS.CocoaTouch.iPad" propertyAccessControl="none" useAutolayout="YES" initialViewController="H1p-Uh-vWS">
|
||||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="9531" systemVersion="15C50" targetRuntime="iOS.CocoaTouch.iPad" propertyAccessControl="none" useAutolayout="YES" initialViewController="H1p-Uh-vWS">
|
||||
<dependencies>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="7703"/>
|
||||
<deployment identifier="iOS"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="9529"/>
|
||||
</dependencies>
|
||||
<scenes>
|
||||
<!--Navigation Controller-->
|
||||
|
|
@ -22,13 +23,13 @@
|
|||
<!--Detail-->
|
||||
<scene sceneID="yUG-lL-AsK">
|
||||
<objects>
|
||||
<viewController title="Detail" id="JEX-9P-axG" customClass="DetailView" sceneMemberID="viewController">
|
||||
<viewController title="Detail" id="JEX-9P-axG" customClass="DetailTableView" sceneMemberID="viewController">
|
||||
<tableView key="view" clipsSubviews="YES" contentMode="scaleToFill" alwaysBounceVertical="YES" dataMode="prototypes" style="plain" separatorStyle="default" rowHeight="44" sectionHeaderHeight="22" sectionFooterHeight="22" id="aVY-Yw-ztG">
|
||||
<rect key="frame" x="0.0" y="0.0" width="703" height="768"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
|
||||
<prototypes>
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="blue" indentationWidth="10" textLabel="6lf-XI-z9S" style="IBUITableViewCellStyleDefault" id="fGk-UB-StR">
|
||||
<tableViewCell contentMode="scaleToFill" selectionStyle="blue" indentationWidth="10" reuseIdentifier="testCellIdentifier" textLabel="6lf-XI-z9S" style="IBUITableViewCellStyleDefault" id="fGk-UB-StR">
|
||||
<rect key="frame" x="0.0" y="86" width="703" height="44"/>
|
||||
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
|
||||
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="fGk-UB-StR" id="oMv-Vp-OY1">
|
||||
|
|
@ -36,7 +37,7 @@
|
|||
<autoresizingMask key="autoresizingMask"/>
|
||||
<subviews>
|
||||
<label opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="left" text="Title" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" id="6lf-XI-z9S">
|
||||
<rect key="frame" x="15" y="0.0" width="673" height="43"/>
|
||||
<rect key="frame" x="35" y="0.0" width="633" height="43"/>
|
||||
<autoresizingMask key="autoresizingMask"/>
|
||||
<fontDescription key="fontDescription" type="system" pointSize="18"/>
|
||||
<color key="textColor" cocoaTouchSystemColor="darkTextColor"/>
|
||||
|
|
@ -46,6 +47,7 @@
|
|||
</tableViewCellContentView>
|
||||
</tableViewCell>
|
||||
</prototypes>
|
||||
<sections/>
|
||||
</tableView>
|
||||
<toolbarItems/>
|
||||
<navigationItem key="navigationItem" title="Detail" id="mOI-FS-AaM"/>
|
||||
|
|
@ -125,9 +127,4 @@
|
|||
<point key="canvasLocation" x="-366" y="248"/>
|
||||
</scene>
|
||||
</scenes>
|
||||
<simulatedMetricsContainer key="defaultSimulatedMetrics">
|
||||
<simulatedStatusBarMetrics key="statusBar"/>
|
||||
<simulatedOrientationMetrics key="orientation"/>
|
||||
<simulatedScreenMetrics key="destination"/>
|
||||
</simulatedMetricsContainer>
|
||||
</document>
|
||||
|
|
|
|||
|
|
@ -1,7 +1,8 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="7706" systemVersion="14D136" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" initialViewController="rS3-R9-Ivy">
|
||||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="9531" systemVersion="15C50" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" initialViewController="rS3-R9-Ivy">
|
||||
<dependencies>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="7703"/>
|
||||
<deployment identifier="iOS"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="9529"/>
|
||||
</dependencies>
|
||||
<scenes>
|
||||
<!--Navigation Controller-->
|
||||
|
|
@ -65,7 +66,7 @@
|
|||
<!--Detail-->
|
||||
<scene sceneID="Cn3-H9-jdl">
|
||||
<objects>
|
||||
<viewController title="Detail" id="Ah7-4n-0Wa" customClass="DetailView" sceneMemberID="viewController">
|
||||
<viewController title="Detail" id="Ah7-4n-0Wa" customClass="DetailTableView" sceneMemberID="viewController">
|
||||
<tableView key="view" clipsSubviews="YES" contentMode="scaleToFill" alwaysBounceVertical="YES" dataMode="prototypes" style="plain" separatorStyle="default" rowHeight="44" sectionHeaderHeight="22" sectionFooterHeight="22" id="HbK-cV-Nw3">
|
||||
<rect key="frame" x="0.0" y="0.0" width="320" height="568"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
|
|
@ -97,9 +98,4 @@
|
|||
<point key="canvasLocation" x="1002" y="78"/>
|
||||
</scene>
|
||||
</scenes>
|
||||
<simulatedMetricsContainer key="defaultSimulatedMetrics">
|
||||
<simulatedStatusBarMetrics key="statusBar"/>
|
||||
<simulatedOrientationMetrics key="orientation"/>
|
||||
<simulatedScreenMetrics key="destination" type="retina4"/>
|
||||
</simulatedMetricsContainer>
|
||||
</document>
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ typedef NS_ENUM(int, TestState) { TestStateIdle, TestStatePassed, TestStateInPro
|
|||
|
||||
@end
|
||||
|
||||
@interface DetailView : UITableViewController
|
||||
@interface DetailTableView : UITableViewController
|
||||
|
||||
@property(strong, nonatomic) NSString *detailItem;
|
||||
|
||||
|
|
@ -6,7 +6,7 @@
|
|||
//
|
||||
//
|
||||
|
||||
#import "DetailView.h"
|
||||
#import "DetailTableView.h"
|
||||
#import "MasterView.h"
|
||||
#import "LogsView.h"
|
||||
#include "linphone/liblinphone_tester.h"
|
||||
|
|
@ -36,7 +36,7 @@ static NSString *const kAllTestsName = @"Run All tests";
|
|||
|
||||
@end
|
||||
|
||||
@interface DetailView () {
|
||||
@interface DetailTableView () {
|
||||
NSMutableArray *_tests;
|
||||
BOOL in_progress;
|
||||
}
|
||||
|
|
@ -44,7 +44,7 @@ static NSString *const kAllTestsName = @"Run All tests";
|
|||
- (void)configureView;
|
||||
@end
|
||||
|
||||
@implementation DetailView
|
||||
@implementation DetailTableView
|
||||
|
||||
#pragma mark - Managing the detail item
|
||||
|
||||
|
|
@ -113,7 +113,11 @@ static NSString *const kAllTestsName = @"Run All tests";
|
|||
}
|
||||
|
||||
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
|
||||
UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:@"testCellIdentifier" forIndexPath:indexPath];
|
||||
static NSString *kCellId = @"testCellIdentifier";
|
||||
UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:kCellId forIndexPath:indexPath];
|
||||
if (cell == nil) {
|
||||
cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:kCellId];
|
||||
}
|
||||
|
||||
TestItem *test = _tests[indexPath.row];
|
||||
cell.textLabel.text = [NSString stringWithFormat:@"%@/%@", test.suite, test.name];
|
||||
|
|
@ -36,6 +36,8 @@
|
|||
<array>
|
||||
<string>armv7</string>
|
||||
</array>
|
||||
<key>UIRequiresFullScreen</key>
|
||||
<true/>
|
||||
<key>UIStatusBarTintParameters</key>
|
||||
<dict>
|
||||
<key>UINavigationBar</key>
|
||||
|
|
|
|||
|
|
@ -11,10 +11,10 @@
|
|||
extern NSMutableArray *lastLogs;
|
||||
extern NSString *const kLogsUpdateNotification;
|
||||
|
||||
@class DetailView;
|
||||
@class DetailTableView;
|
||||
|
||||
@interface MasterView : UITableViewController
|
||||
|
||||
@property(strong, nonatomic) DetailView *detailViewController;
|
||||
@property(strong, nonatomic) DetailTableView *detailViewController;
|
||||
|
||||
@end
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@
|
|||
|
||||
#import "MasterView.h"
|
||||
#import "LogsView.h"
|
||||
#import "DetailView.h"
|
||||
#import "DetailTableView.h"
|
||||
|
||||
#include "linphone/liblinphone_tester.h"
|
||||
#include "mediastreamer2/msutils.h"
|
||||
|
|
@ -40,15 +40,18 @@ NSString *const kLogsUpdateNotification = @"kLogsUpdateNotification";
|
|||
- (void)setupLogging {
|
||||
lastLogs = [[NSMutableArray alloc] initWithCapacity:kLastLogsCapacity];
|
||||
logsBuffer = [NSMutableArray arrayWithCapacity:kLogsBufferCapacity];
|
||||
[Log enableLogs:YES];
|
||||
}
|
||||
|
||||
linphone_core_set_log_level(ORTP_MESSAGE);
|
||||
linphone_core_set_log_handler((OrtpLogFunc)linphone_iphone_log_handler);
|
||||
void tester_logs_handler(int level, const char *fmt, va_list args) {
|
||||
linphone_iphone_log_handler(NULL, level, fmt, args);
|
||||
}
|
||||
|
||||
- (void)viewDidLoad {
|
||||
[super viewDidLoad];
|
||||
// Do any additional setup after loading the view, typically from a nib.
|
||||
self.detailViewController = (DetailView *)[[self.splitViewController.viewControllers lastObject] topViewController];
|
||||
self.detailViewController =
|
||||
(DetailTableView *)[[self.splitViewController.viewControllers lastObject] topViewController];
|
||||
|
||||
[self setupLogging];
|
||||
|
||||
|
|
@ -56,7 +59,7 @@ NSString *const kLogsUpdateNotification = @"kLogsUpdateNotification";
|
|||
NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES);
|
||||
documentPath = [paths objectAtIndex:0];
|
||||
|
||||
bc_tester_init((void (*)(int, const char *fm, va_list))linphone_iphone_log_handler, ORTP_MESSAGE, ORTP_ERROR);
|
||||
bc_tester_init(tester_logs_handler, ORTP_MESSAGE, ORTP_ERROR);
|
||||
liblinphone_tester_add_suites();
|
||||
|
||||
bc_tester_set_resource_dir_prefix([bundlePath UTF8String]);
|
||||
|
|
|
|||
6
LiblinphoneTester/TesterImages.xcassets/Contents.json
Normal file
6
LiblinphoneTester/TesterImages.xcassets/Contents.json
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
{
|
||||
"info" : {
|
||||
"version" : 1,
|
||||
"author" : "xcode"
|
||||
}
|
||||
}
|
||||
|
|
@ -10,11 +10,21 @@
|
|||
"size" : "29x29",
|
||||
"scale" : "2x"
|
||||
},
|
||||
{
|
||||
"idiom" : "iphone",
|
||||
"size" : "29x29",
|
||||
"scale" : "3x"
|
||||
},
|
||||
{
|
||||
"idiom" : "iphone",
|
||||
"size" : "40x40",
|
||||
"scale" : "2x"
|
||||
},
|
||||
{
|
||||
"idiom" : "iphone",
|
||||
"size" : "40x40",
|
||||
"scale" : "3x"
|
||||
},
|
||||
{
|
||||
"idiom" : "iphone",
|
||||
"size" : "57x57",
|
||||
|
|
@ -84,6 +94,11 @@
|
|||
"idiom" : "ipad",
|
||||
"size" : "76x76",
|
||||
"scale" : "2x"
|
||||
},
|
||||
{
|
||||
"idiom" : "ipad",
|
||||
"size" : "83.5x83.5",
|
||||
"scale" : "2x"
|
||||
}
|
||||
],
|
||||
"info" : {
|
||||
|
|
|
|||
|
|
@ -1,89 +0,0 @@
|
|||
{
|
||||
"images" : [
|
||||
{
|
||||
"idiom" : "iphone",
|
||||
"scale" : "1x",
|
||||
"orientation" : "portrait"
|
||||
},
|
||||
{
|
||||
"idiom" : "iphone",
|
||||
"scale" : "2x",
|
||||
"orientation" : "portrait"
|
||||
},
|
||||
{
|
||||
"orientation" : "portrait",
|
||||
"idiom" : "iphone",
|
||||
"subtype" : "retina4",
|
||||
"scale" : "2x"
|
||||
},
|
||||
{
|
||||
"orientation" : "portrait",
|
||||
"idiom" : "iphone",
|
||||
"minimum-system-version" : "7.0",
|
||||
"scale" : "2x"
|
||||
},
|
||||
{
|
||||
"orientation" : "portrait",
|
||||
"idiom" : "iphone",
|
||||
"minimum-system-version" : "7.0",
|
||||
"subtype" : "retina4",
|
||||
"scale" : "2x"
|
||||
},
|
||||
{
|
||||
"orientation" : "portrait",
|
||||
"idiom" : "ipad",
|
||||
"extent" : "to-status-bar",
|
||||
"scale" : "1x"
|
||||
},
|
||||
{
|
||||
"orientation" : "portrait",
|
||||
"idiom" : "ipad",
|
||||
"extent" : "to-status-bar",
|
||||
"scale" : "2x"
|
||||
},
|
||||
{
|
||||
"orientation" : "landscape",
|
||||
"idiom" : "ipad",
|
||||
"extent" : "to-status-bar",
|
||||
"scale" : "1x"
|
||||
},
|
||||
{
|
||||
"orientation" : "landscape",
|
||||
"idiom" : "ipad",
|
||||
"extent" : "to-status-bar",
|
||||
"scale" : "2x"
|
||||
},
|
||||
{
|
||||
"orientation" : "portrait",
|
||||
"idiom" : "ipad",
|
||||
"minimum-system-version" : "7.0",
|
||||
"extent" : "full-screen",
|
||||
"scale" : "1x"
|
||||
},
|
||||
{
|
||||
"orientation" : "portrait",
|
||||
"idiom" : "ipad",
|
||||
"minimum-system-version" : "7.0",
|
||||
"extent" : "full-screen",
|
||||
"scale" : "2x"
|
||||
},
|
||||
{
|
||||
"orientation" : "landscape",
|
||||
"idiom" : "ipad",
|
||||
"minimum-system-version" : "7.0",
|
||||
"extent" : "full-screen",
|
||||
"scale" : "1x"
|
||||
},
|
||||
{
|
||||
"orientation" : "landscape",
|
||||
"idiom" : "ipad",
|
||||
"minimum-system-version" : "7.0",
|
||||
"extent" : "full-screen",
|
||||
"scale" : "2x"
|
||||
}
|
||||
],
|
||||
"info" : {
|
||||
"version" : 1,
|
||||
"author" : "xcode"
|
||||
}
|
||||
}
|
||||
BIN
LiblinphoneTester/test_failed.png
Normal file
BIN
LiblinphoneTester/test_failed.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.2 KiB |
BIN
LiblinphoneTester/test_inprogress.png
Normal file
BIN
LiblinphoneTester/test_inprogress.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.2 KiB |
BIN
LiblinphoneTester/test_passed.png
Normal file
BIN
LiblinphoneTester/test_passed.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.1 KiB |
|
|
@ -30,11 +30,14 @@
|
|||
return [[testString componentsSeparatedByCharactersInSet:charactersToRemove] componentsJoinedByString:@"_"];
|
||||
}
|
||||
|
||||
+ (void)initialize {
|
||||
void tester_logs_handler(int level, const char *fmt, va_list args) {
|
||||
linphone_iphone_log_handler(NULL, level, fmt, args);
|
||||
}
|
||||
|
||||
+ (void)initialize {
|
||||
static char *bundle = NULL;
|
||||
static char *documents = NULL;
|
||||
bc_tester_init((void (*)(int, const char *fm, va_list))linphone_iphone_log_handler, ORTP_MESSAGE, ORTP_ERROR);
|
||||
bc_tester_init(tester_logs_handler, ORTP_MESSAGE, ORTP_ERROR);
|
||||
liblinphone_tester_add_suites();
|
||||
|
||||
NSString *bundlePath = [[NSBundle mainBundle] bundlePath];
|
||||
|
|
|
|||
|
|
@ -48,7 +48,6 @@
|
|||
|
||||
- (void)beforeEach {
|
||||
[[LinphoneManager instance] lpConfigSetInt:NO forKey:@"animations_preference"];
|
||||
linphone_core_set_log_level(ORTP_MESSAGE);
|
||||
}
|
||||
|
||||
- (NSString *)me {
|
||||
|
|
|
|||
|
|
@ -51,7 +51,7 @@
|
|||
63058A271B4E821E00EFAE36 /* Main_iPhone.strings in Resources */ = {isa = PBXBuildFile; fileRef = 63058A131B4E821E00EFAE36 /* Main_iPhone.strings */; };
|
||||
63058A281B4E821E00EFAE36 /* Main_iPad.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 63058A151B4E821E00EFAE36 /* Main_iPad.storyboard */; };
|
||||
63058A291B4E821E00EFAE36 /* Main_iPhone.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 63058A171B4E821E00EFAE36 /* Main_iPhone.storyboard */; };
|
||||
63058A2A1B4E821E00EFAE36 /* DetailView.m in Sources */ = {isa = PBXBuildFile; fileRef = 63058A1A1B4E821E00EFAE36 /* DetailView.m */; };
|
||||
63058A2A1B4E821E00EFAE36 /* DetailTableView.m in Sources */ = {isa = PBXBuildFile; fileRef = 63058A1A1B4E821E00EFAE36 /* DetailTableView.m */; };
|
||||
63058A2C1B4E821E00EFAE36 /* LogsView.m in Sources */ = {isa = PBXBuildFile; fileRef = 63058A1F1B4E821E00EFAE36 /* LogsView.m */; };
|
||||
63058A2D1B4E821E00EFAE36 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 63058A201B4E821E00EFAE36 /* main.m */; };
|
||||
63058A2E1B4E821E00EFAE36 /* MasterView.m in Sources */ = {isa = PBXBuildFile; fileRef = 63058A221B4E821E00EFAE36 /* MasterView.m */; };
|
||||
|
|
@ -544,6 +544,10 @@
|
|||
63D11C531C3D501200E8FCEE /* Log.m in Sources */ = {isa = PBXBuildFile; fileRef = 63D11C521C3D501200E8FCEE /* Log.m */; };
|
||||
63D11C551C3D50A100E8FCEE /* Log.m in Sources */ = {isa = PBXBuildFile; fileRef = 63D11C521C3D501200E8FCEE /* Log.m */; };
|
||||
63DFE04B1C40161700DA5E87 /* notes_of_the_optimistic.caf in Resources */ = {isa = PBXBuildFile; fileRef = 63DFE0451C40161700DA5E87 /* notes_of_the_optimistic.caf */; };
|
||||
63E279DD1C4F8CEE00D332AE /* Default-568h@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 63E279DC1C4F8CEE00D332AE /* Default-568h@2x.png */; };
|
||||
63E279E71C4F9A2500D332AE /* test_failed.png in Resources */ = {isa = PBXBuildFile; fileRef = 63E279E41C4F9A2500D332AE /* test_failed.png */; };
|
||||
63E279E81C4F9A2500D332AE /* test_inprogress.png in Resources */ = {isa = PBXBuildFile; fileRef = 63E279E51C4F9A2500D332AE /* test_inprogress.png */; };
|
||||
63E279E91C4F9A2500D332AE /* test_passed.png in Resources */ = {isa = PBXBuildFile; fileRef = 63E279E61C4F9A2500D332AE /* test_passed.png */; };
|
||||
63E59A3F1ADE70D900646FB3 /* InAppProductsManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 63E59A3E1ADE70D900646FB3 /* InAppProductsManager.m */; };
|
||||
63EEE3FF1BBA9AC00087D3AF /* libcunit.a in Frameworks */ = {isa = PBXBuildFile; fileRef = F03A9B7E18C0D9C900C4D7FE /* libcunit.a */; };
|
||||
63EEE4001BBA9AC00087D3AF /* liblinphonetester.a in Frameworks */ = {isa = PBXBuildFile; fileRef = F0BB8C0F193623F200974404 /* liblinphonetester.a */; };
|
||||
|
|
@ -852,8 +856,8 @@
|
|||
63058A141B4E821E00EFAE36 /* ar */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = ar; path = ar.lproj/Main_iPhone.strings; sourceTree = "<group>"; };
|
||||
63058A161B4E821E00EFAE36 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main_iPad.storyboard; sourceTree = "<group>"; };
|
||||
63058A181B4E821E00EFAE36 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main_iPhone.storyboard; sourceTree = "<group>"; };
|
||||
63058A191B4E821E00EFAE36 /* DetailView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DetailView.h; sourceTree = "<group>"; };
|
||||
63058A1A1B4E821E00EFAE36 /* DetailView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = DetailView.m; sourceTree = "<group>"; };
|
||||
63058A191B4E821E00EFAE36 /* DetailTableView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DetailTableView.h; sourceTree = "<group>"; };
|
||||
63058A1A1B4E821E00EFAE36 /* DetailTableView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = DetailTableView.m; sourceTree = "<group>"; };
|
||||
63058A1B1B4E821E00EFAE36 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = "<group>"; };
|
||||
63058A1C1B4E821E00EFAE36 /* LinphoneTester-Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = "LinphoneTester-Info.plist"; sourceTree = "<group>"; };
|
||||
63058A1D1B4E821E00EFAE36 /* LinphoneTester-Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "LinphoneTester-Prefix.pch"; sourceTree = "<group>"; };
|
||||
|
|
@ -1357,6 +1361,10 @@
|
|||
63D11C521C3D501200E8FCEE /* Log.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = Log.m; path = Utils/Log.m; sourceTree = "<group>"; };
|
||||
63D11C541C3D503A00E8FCEE /* Log.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = Log.h; sourceTree = "<group>"; };
|
||||
63DFE0451C40161700DA5E87 /* notes_of_the_optimistic.caf */ = {isa = PBXFileReference; lastKnownFileType = file; path = notes_of_the_optimistic.caf; sourceTree = "<group>"; };
|
||||
63E279DC1C4F8CEE00D332AE /* Default-568h@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-568h@2x.png"; sourceTree = "<group>"; };
|
||||
63E279E41C4F9A2500D332AE /* test_failed.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = test_failed.png; path = LiblinphoneTester/test_failed.png; sourceTree = SOURCE_ROOT; };
|
||||
63E279E51C4F9A2500D332AE /* test_inprogress.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = test_inprogress.png; path = LiblinphoneTester/test_inprogress.png; sourceTree = SOURCE_ROOT; };
|
||||
63E279E61C4F9A2500D332AE /* test_passed.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = test_passed.png; path = LiblinphoneTester/test_passed.png; sourceTree = SOURCE_ROOT; };
|
||||
63E59A3D1ADE6ECB00646FB3 /* InAppProductsManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = InAppProductsManager.h; sourceTree = "<group>"; };
|
||||
63E59A3E1ADE70D900646FB3 /* InAppProductsManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = InAppProductsManager.m; sourceTree = "<group>"; };
|
||||
63EA4C941B50189D00922857 /* libmswebrtc.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libmswebrtc.a; path = "liblinphone-sdk/apple-darwin/lib/mediastreamer/plugins/libmswebrtc.a"; sourceTree = "<group>"; };
|
||||
|
|
@ -1932,6 +1940,7 @@
|
|||
29B97314FDCFA39411CA2CEA /* CustomTemplate */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
63E279DC1C4F8CEE00D332AE /* Default-568h@2x.png */,
|
||||
080E96DDFE201D6D7F000001 /* Classes */,
|
||||
29B97323FDCFA39411CA2CEA /* Frameworks */,
|
||||
F0938158188E629800A55DFA /* iTunesArtwork */,
|
||||
|
|
@ -2082,8 +2091,8 @@
|
|||
63058A131B4E821E00EFAE36 /* Main_iPhone.strings */,
|
||||
63058A151B4E821E00EFAE36 /* Main_iPad.storyboard */,
|
||||
63058A171B4E821E00EFAE36 /* Main_iPhone.storyboard */,
|
||||
63058A191B4E821E00EFAE36 /* DetailView.h */,
|
||||
63058A1A1B4E821E00EFAE36 /* DetailView.m */,
|
||||
63058A191B4E821E00EFAE36 /* DetailTableView.h */,
|
||||
63058A1A1B4E821E00EFAE36 /* DetailTableView.m */,
|
||||
63058A1C1B4E821E00EFAE36 /* LinphoneTester-Info.plist */,
|
||||
63058A1D1B4E821E00EFAE36 /* LinphoneTester-Prefix.pch */,
|
||||
63058A1E1B4E821E00EFAE36 /* LogsView.h */,
|
||||
|
|
@ -2126,6 +2135,9 @@
|
|||
636B967C1C298400003BA37C /* images */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
63E279E41C4F9A2500D332AE /* test_failed.png */,
|
||||
63E279E51C4F9A2500D332AE /* test_inprogress.png */,
|
||||
63E279E61C4F9A2500D332AE /* test_passed.png */,
|
||||
636B967D1C298400003BA37C /* add_field_default.png */,
|
||||
636B967E1C298400003BA37C /* add_field_default@2x.png */,
|
||||
636B967F1C298400003BA37C /* add_field_over.png */,
|
||||
|
|
@ -3341,10 +3353,14 @@
|
|||
63058ADD1B4E937300EFAE36 /* marie_xml in Resources */,
|
||||
63058ADE1B4E937300EFAE36 /* messages.db in Resources */,
|
||||
63058ADF1B4E937300EFAE36 /* rcfiles in Resources */,
|
||||
63E279E71C4F9A2500D332AE /* test_failed.png in Resources */,
|
||||
63E279E81C4F9A2500D332AE /* test_inprogress.png in Resources */,
|
||||
63058AE01B4E937300EFAE36 /* sounds in Resources */,
|
||||
63058AE21B4E93A100EFAE36 /* tester_hosts in Resources */,
|
||||
63E279DD1C4F8CEE00D332AE /* Default-568h@2x.png in Resources */,
|
||||
63058A2F1B4E821E00EFAE36 /* TesterImages.xcassets in Resources */,
|
||||
63058A251B4E821E00EFAE36 /* InfoPlist.strings in Resources */,
|
||||
63E279E91C4F9A2500D332AE /* test_passed.png in Resources */,
|
||||
63058A271B4E821E00EFAE36 /* Main_iPhone.strings in Resources */,
|
||||
63058A261B4E821E00EFAE36 /* Main_iPad.strings in Resources */,
|
||||
63058A291B4E821E00EFAE36 /* Main_iPhone.storyboard in Resources */,
|
||||
|
|
@ -3525,7 +3541,7 @@
|
|||
63D11C551C3D50A100E8FCEE /* Log.m in Sources */,
|
||||
63058A2D1B4E821E00EFAE36 /* main.m in Sources */,
|
||||
63058A241B4E821E00EFAE36 /* AppDelegate.m in Sources */,
|
||||
63058A2A1B4E821E00EFAE36 /* DetailView.m in Sources */,
|
||||
63058A2A1B4E821E00EFAE36 /* DetailTableView.m in Sources */,
|
||||
63058A2E1B4E821E00EFAE36 /* MasterView.m in Sources */,
|
||||
63058A2C1B4E821E00EFAE36 /* LogsView.m in Sources */,
|
||||
);
|
||||
|
|
@ -4054,6 +4070,8 @@
|
|||
HEADER_SEARCH_PATHS = "";
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 6.0;
|
||||
LIBRARY_SEARCH_PATHS = "";
|
||||
OTHER_CFLAGS = "-DORTP_LOG_DOMAIN=\\\"ios\\\"";
|
||||
OTHER_CPLUSPLUSFLAGS = "$(OTHER_CFLAGS)";
|
||||
PROVISIONING_PROFILE = "0636A6EA-90EB-4D92-B707-19FC32F9A7CF";
|
||||
SDKROOT = iphoneos;
|
||||
STANDARD_C_PLUS_PLUS_LIBRARY_TYPE = dynamic;
|
||||
|
|
@ -4139,6 +4157,8 @@
|
|||
HEADER_SEARCH_PATHS = "";
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 6.0;
|
||||
LIBRARY_SEARCH_PATHS = "";
|
||||
OTHER_CFLAGS = "-DORTP_LOG_DOMAIN=\\\"ios\\\"";
|
||||
OTHER_CPLUSPLUSFLAGS = "$(OTHER_CFLAGS)";
|
||||
PROVISIONING_PROFILE = "";
|
||||
SDKROOT = iphoneos;
|
||||
STANDARD_C_PLUS_PLUS_LIBRARY_TYPE = dynamic;
|
||||
|
|
@ -4224,6 +4244,8 @@
|
|||
HEADER_SEARCH_PATHS = "";
|
||||
IPHONEOS_DEPLOYMENT_TARGET = 6.0;
|
||||
LIBRARY_SEARCH_PATHS = "";
|
||||
OTHER_CFLAGS = "-DORTP_LOG_DOMAIN=\\\"ios\\\"";
|
||||
OTHER_CPLUSPLUSFLAGS = "$(OTHER_CFLAGS)";
|
||||
PROVISIONING_PROFILE = "C7F794BC-6D48-41F2-B37D-E1B1B1A40901";
|
||||
SDKROOT = iphoneos;
|
||||
STANDARD_C_PLUS_PLUS_LIBRARY_TYPE = dynamic;
|
||||
|
|
@ -4311,6 +4333,8 @@
|
|||
IPHONEOS_DEPLOYMENT_TARGET = 6.0;
|
||||
LIBRARY_SEARCH_PATHS = "";
|
||||
ONLY_ACTIVE_ARCH = YES;
|
||||
OTHER_CFLAGS = "-DORTP_LOG_DOMAIN=\\\"ios\\\"";
|
||||
OTHER_CPLUSPLUSFLAGS = "$(OTHER_CFLAGS)";
|
||||
PROVISIONING_PROFILE = "2AC0DC11-4546-47B6-8B8A-453CCA80903C";
|
||||
SDKROOT = iphoneos;
|
||||
STANDARD_C_PLUS_PLUS_LIBRARY_TYPE = dynamic;
|
||||
|
|
@ -4510,7 +4534,6 @@
|
|||
buildSettings = {
|
||||
ALWAYS_SEARCH_USER_PATHS = NO;
|
||||
ASSETCATALOG_COMPILER_APPICON_NAME = TestAppIcon;
|
||||
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = TestLaunchImage;
|
||||
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
|
||||
CLANG_CXX_LIBRARY = "libc++";
|
||||
CLANG_ENABLE_MODULES = YES;
|
||||
|
|
@ -4567,7 +4590,6 @@
|
|||
buildSettings = {
|
||||
ALWAYS_SEARCH_USER_PATHS = NO;
|
||||
ASSETCATALOG_COMPILER_APPICON_NAME = TestAppIcon;
|
||||
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = TestLaunchImage;
|
||||
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
|
||||
CLANG_CXX_LIBRARY = "libc++";
|
||||
CLANG_ENABLE_MODULES = YES;
|
||||
|
|
@ -4618,7 +4640,6 @@
|
|||
buildSettings = {
|
||||
ALWAYS_SEARCH_USER_PATHS = NO;
|
||||
ASSETCATALOG_COMPILER_APPICON_NAME = TestAppIcon;
|
||||
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = TestLaunchImage;
|
||||
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
|
||||
CLANG_CXX_LIBRARY = "libc++";
|
||||
CLANG_ENABLE_MODULES = YES;
|
||||
|
|
@ -4669,7 +4690,6 @@
|
|||
buildSettings = {
|
||||
ALWAYS_SEARCH_USER_PATHS = NO;
|
||||
ASSETCATALOG_COMPILER_APPICON_NAME = TestAppIcon;
|
||||
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = TestLaunchImage;
|
||||
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
|
||||
CLANG_CXX_LIBRARY = "libc++";
|
||||
CLANG_ENABLE_MODULES = YES;
|
||||
|
|
|
|||
|
|
@ -1 +1 @@
|
|||
Subproject commit 67f9bd2068ab6d040ddadd4209a538aef99a893a
|
||||
Subproject commit 8508f5435738598b646b37fc5ecb951ecd000281
|
||||
Loading…
Add table
Reference in a new issue