Skip to content

Commit

Permalink
Updated Lingo reference
Browse files Browse the repository at this point in the history
- Referencing Lingo 3.1.0
- Adapted tests for Vapor 4
- Updated READNE.md
  • Loading branch information
miroslavkovac committed Apr 10, 2021
1 parent 20c805c commit f6f38c9
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 3 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@
/.build
/*.xcodeproj
Package.resolved
.swiftpm
2 changes: 1 addition & 1 deletion Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ let package = Package(
],
dependencies: [
.package(url: "https://github.com/vapor/vapor.git", from: "4.27.0"),
.package(url: "https://github.com/miroslavkovac/Lingo.git", from: "3.0.5")
.package(url: "https://github.com/miroslavkovac/Lingo.git", from: "3.1.0")
],
targets: [
.target(name: "LingoVapor", dependencies: [
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Lingo Provider

[![Language](https://img.shields.io/badge/Swift-4-brightgreen.svg)](http://swift.org)
[![Language](https://img.shields.io/badge/Swift-5-brightgreen.svg)](http://swift.org)
[![GitHub license](https://img.shields.io/badge/license-MIT-blue.svg)](https://raw.githubusercontent.com/vapor-community/markdown-provider/master/LICENSE)

A Vapor provider for [Lingo](https://github.com/miroslavkovac/Lingo) - a pure Swift localization library ready to be used in Server Side Swift projects.
Expand Down
14 changes: 13 additions & 1 deletion Tests/LingoVaporTests/LingoVaporTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,20 @@ import XCTest

class LingoVaporTests: XCTestCase {

private var application: Application!

override func setUp() {
super.setUp()
self.application = Application()
}

override func tearDown() {
self.application.shutdown()
super.tearDown()
}

func testInitialization() throws {
var lingoProvider = LingoProvider(application: Application())
let lingoProvider = LingoProvider(application: self.application)
lingoProvider.configuration = .init(defaultLocale: "en", localizationsDir: "Localizations")
XCTAssertEqual(lingoProvider.configuration?.defaultLocale, "en")
}
Expand Down

0 comments on commit f6f38c9

Please sign in to comment.