mirror of
https://github.com/nicoverbruggen/phpmon.git
synced 2025-08-08 04:20:07 +02:00
✨ Add fake isolation interaction
This commit is contained in:
@ -91,7 +91,7 @@
|
|||||||
</CommandLineArgument>
|
</CommandLineArgument>
|
||||||
<CommandLineArgument
|
<CommandLineArgument
|
||||||
argument = "--configuration:~/.phpmon_fconf_working.json"
|
argument = "--configuration:~/.phpmon_fconf_working.json"
|
||||||
isEnabled = "NO">
|
isEnabled = "YES">
|
||||||
</CommandLineArgument>
|
</CommandLineArgument>
|
||||||
<CommandLineArgument
|
<CommandLineArgument
|
||||||
argument = "--configuration:~/.phpmon_fconf_broken.json"
|
argument = "--configuration:~/.phpmon_fconf_broken.json"
|
||||||
|
@ -28,6 +28,20 @@ class FakeValetInteractor: ValetInteractor {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
override func isolate(site: ValetSite, version: String) async throws {
|
||||||
|
await delay(seconds: delayTime)
|
||||||
|
|
||||||
|
site.isolatedPhpVersion = PhpEnv.shared.cachedPhpInstallations[version]
|
||||||
|
site.evaluateCompatibility()
|
||||||
|
}
|
||||||
|
|
||||||
|
override func unisolate(site: ValetSite) async throws {
|
||||||
|
await delay(seconds: delayTime)
|
||||||
|
|
||||||
|
site.isolatedPhpVersion = nil
|
||||||
|
site.evaluateCompatibility()
|
||||||
|
}
|
||||||
|
|
||||||
override func remove(proxy: ValetProxy) async throws {
|
override func remove(proxy: ValetProxy) async throws {
|
||||||
await delay(seconds: delayTime)
|
await delay(seconds: delayTime)
|
||||||
#warning("A fake proxy scanner needs to be added")
|
#warning("A fake proxy scanner needs to be added")
|
||||||
|
@ -135,7 +135,10 @@ class ValetSite: ValetListable {
|
|||||||
public func determineComposerPhpVersion() {
|
public func determineComposerPhpVersion() {
|
||||||
self.determineComposerInformation()
|
self.determineComposerInformation()
|
||||||
self.determineValetPhpFileInfo()
|
self.determineValetPhpFileInfo()
|
||||||
|
self.evaluateCompatibility()
|
||||||
|
}
|
||||||
|
|
||||||
|
public func evaluateCompatibility() {
|
||||||
if self.composerPhp == "???" {
|
if self.composerPhp == "???" {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user