mirror of
https://github.com/nicoverbruggen/phpmon.git
synced 2026-03-28 15:00:06 +01:00
♻️ Refactor tests to Swift Testing
This commit is contained in:
26
tests/unit/Commands/CommandTest.swift
Normal file
26
tests/unit/Commands/CommandTest.swift
Normal file
@@ -0,0 +1,26 @@
|
||||
//
|
||||
// CommandTest.swift
|
||||
// PHP Monitor
|
||||
//
|
||||
// Created by Nico Verbruggen on 13/02/2021.
|
||||
// Copyright © 2023 Nico Verbruggen. All rights reserved.
|
||||
//
|
||||
|
||||
import Testing
|
||||
|
||||
struct CommandTest {
|
||||
@Test func determinePhpVersion() {
|
||||
let container = Container.real()
|
||||
|
||||
let version = container.command.execute(
|
||||
path: container.paths.php,
|
||||
arguments: ["-v"],
|
||||
trimNewlines: false
|
||||
)
|
||||
|
||||
#expect(version.contains("(cli)"))
|
||||
#expect(version.contains("NTS"))
|
||||
#expect(version.contains("built"))
|
||||
#expect(version.contains("Zend"))
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user