protobuf-swift/plugin/Tests/PluginTest.swift

36 lines
1.1 KiB
Swift

//
// PluginTest.swift
// Tests
//
// Created by Alexey Khokhlov on 18.10.2017.
//
import XCTest
import ProtocolBuffers
class PluginTest: XCTestCase {
// func testParse() {
// let data = Data(base64Encoded: testData)
// let request = try! Google.Protobuf.Compiler.CodeGeneratorRequest.parseFrom(data: data!)
// let generate = request.protoFile.filter({
// return request.fileToGenerate.contains($0.name)
// })
//
// generate.forEach({ file in
// file.messageType.forEach({ message in
// if message.options != nil {
// if message.options.hasExtension(extensions: Google.Protobuf.SwiftDescriptorRoot.swiftMessageOptions()) {
// if let option = message.options.getExtension(extensions: Google.Protobuf.SwiftDescriptorRoot.swiftMessageOptions()) as? Google.Protobuf.SwiftMessageOptions {
// print(option.generateRealmObject)
// }
// }
// }
// })
// })
// XCTAssertNotNil(request)
//
// }
}