ActionSheetSectionTitleTests.swift 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. //
  2. // ActionSheetSectionTitleTests.swift
  3. // Sheeeeeeeeet
  4. //
  5. // Created by Daniel Saidi on 2017-11-26.
  6. // Copyright © 2017 Daniel Saidi. All rights reserved.
  7. //
  8. import Quick
  9. import Nimble
  10. import Sheeeeeeeeet
  11. class ActionSheetSectionTitleTests: QuickSpec {
  12. override func spec() {
  13. var item: ActionSheetSectionTitle!
  14. describe("instance") {
  15. it("is correctly configured") {
  16. item = ActionSheetSectionTitle(title: "foo", subtitle: "bar")
  17. expect(item.title).to(equal("foo"))
  18. expect(item.subtitle).to(equal("bar"))
  19. expect(item.tapBehavior).to(equal(ActionSheetItem.TapBehavior.none))
  20. }
  21. }
  22. describe("cell") {
  23. it("is of correct type") {
  24. item = ActionSheetSectionTitle(title: "foo")
  25. let cell = item.cell(for: UITableView())
  26. expect(cell is ActionSheetSectionTitleCell).to(beTrue())
  27. expect(cell.reuseIdentifier).to(equal(item.cellReuseIdentifier))
  28. }
  29. }
  30. }
  31. }