[Swift] Fix pod authors in podspec

This commit is contained in:
Jason Gavris
2016-07-18 16:02:32 -04:00
parent 72be69d2ed
commit 9e6896c8f0
6 changed files with 35 additions and 4 deletions

View File

@@ -42,4 +42,30 @@ public class SwiftCodegenTest {
Assert.assertEquals(swiftCodegen.toSwiftyEnumName("entry_name"), "EntryName");
}
@Test
public void testDefaultPodAuthors() throws Exception {
// Given
// When
swiftCodegen.processOpts();
// Then
final String podAuthors = (String) swiftCodegen.additionalProperties().get(SwiftCodegen.POD_AUTHORS);
Assert.assertEquals(podAuthors, SwiftCodegen.DEFAULT_POD_AUTHORS);
}
@Test
public void testPodAuthors() throws Exception {
// Given
final String swaggerDevs = "Swagger Devs";
swiftCodegen.additionalProperties().put(SwiftCodegen.POD_AUTHORS, swaggerDevs);
// When
swiftCodegen.processOpts();
// Then
final String podAuthors = (String) swiftCodegen.additionalProperties().get(SwiftCodegen.POD_AUTHORS);
Assert.assertEquals(podAuthors, swaggerDevs);
}
}