Skip to content

Commit

Permalink
Problem 007 Definition
Browse files Browse the repository at this point in the history
  • Loading branch information
jobearrr committed Jul 15, 2024
1 parent df4fb9a commit 27efebe
Show file tree
Hide file tree
Showing 3 changed files with 50 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .swiftlint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
included:
- Sources
- Tests
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
//
// ReverseIntegerDefinition.swift
// LeetSwift
//
// Created by Jobert Sá on 15/07/2024.
//

import Foundation
import Core

public protocol ReverseIntegerDefinition {
func reverse(_ x: Int) -> Int
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
//
// ReverseIntegerTestCaseProvider.swift
// LeetSwift
//
// Created by Jobert Sá on 15/07/2024.
//

@testable import Core
@testable import TestSupport

protocol ReverseIntegerTestCaseProvider: TestCaseProviding { }

extension ReverseIntegerTestCaseProvider {

func validateInput(_ input: Int) -> Bool {
// TODO: Implement validation
true
}

var data: [TestData<Int, Int>] { [
TestData(
input: 123,
expectedOutput: 321
),
TestData(
input: -123,
expectedOutput: -321
),
TestData(
input: 120,
expectedOutput: 21
)
] }
}

0 comments on commit 27efebe

Please sign in to comment.