ActionSheetTitleTests.swift 1.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. //
  2. // ActionSheetTitleTests.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 ActionSheetTitleTests: QuickSpec {
  12. override func spec() {
  13. var item: ActionSheetTitle!
  14. describe("instance") {
  15. it("is correctly configured") {
  16. item = ActionSheetTitle(title: "foo")
  17. expect(item.title).to(equal("foo"))
  18. expect(item.tapBehavior).to(equal(ActionSheetItem.TapBehavior.none))
  19. }
  20. }
  21. describe("cell") {
  22. it("is of correct type") {
  23. item = ActionSheetTitle(title: "foo")
  24. let cell = item.cell(for: UITableView())
  25. expect(cell is ActionSheetTitleCell).to(beTrue())
  26. expect(cell.reuseIdentifier).to(equal(item.cellReuseIdentifier))
  27. }
  28. }
  29. }
  30. }