-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathpassthrough_tests.mm
77 lines (56 loc) · 2.79 KB
/
passthrough_tests.mm
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
//
// passthrough_tests.mm
// passthrough-tests
//
// Created by Gabriel Beauchemin on 11/11/22.
//
#import <XCTest/XCTest.h>
#import "cppfront.h"
@interface passthrough_tests : XCTestCase
@end
@implementation passthrough_tests
- (void)setUp {
// Put setup code here. This method is called before the invocation of each test method in the class.
/*
g++-10 all-std.cxx -std=c++2a -E > gcc-10-libstdc++-e.cpp2
clang++-12 all-std.cxx -std=c++2a -E > clang-12-libstdc++-e.cpp2
cl all-std.cxx -std:c++latest /E > msvc-msstl-e.cpp2
*/
}
- (void)tearDown {
// Put teardown code here. This method is called after the invocation of each test method in the class.
}
- (void)test_mvsc {
// cppfront msvc-msstl-e.cpp2
// diff -s -Z msvc-msstl-e.cpp2 msvc-msstl-e.cpp
NSString* input = [[NSBundle bundleForClass:[self class]] pathForResource:@"msvc-msstl-e"
ofType:@"cpp2"
inDirectory:@"passthrough-tests"];
NSString* output = [[NSBundle bundleForClass:[self class]] pathForResource:@"msvc-msstl-e"
ofType:@"cpp"
inDirectory:@"passthrough-tests"];
cppfront(input, output, FALSE);
}
- (void)test_gcc10 {
// cppfront gcc-10-libstdc++-e.cpp2
// diff -s -Z gcc-10-libstdc++-e.cpp2 gcc-10-libstdc++-e.cpp
NSString* input = [[NSBundle bundleForClass:[self class]] pathForResource:@"gcc-10-libstdc++-e"
ofType:@"cpp2"
inDirectory:@"passthrough-tests"];
NSString* output = [[NSBundle bundleForClass:[self class]] pathForResource:@"gcc-10-libstdc++-e"
ofType:@"cpp"
inDirectory:@"passthrough-tests"];
cppfront(input, output, FALSE);
}
- (void)test_clang12 {
// cppfront clang-12-libstdc++-e.cpp2
// diff -s -Z clang-12-libstdc++-e.cpp2 clang-12-libstdc++-e.cpp
NSString* input = [[NSBundle bundleForClass:[self class]] pathForResource:@"clang-12-libstdc++-e"
ofType:@"cpp2"
inDirectory:@"passthrough-tests"];
NSString* output = [[NSBundle bundleForClass:[self class]] pathForResource:@"clang-12-libstdc++-e"
ofType:@"cpp"
inDirectory:@"passthrough-tests"];
cppfront(input, output, FALSE);
}
@end