test-bot: handle conflicted formulas and unlinked dependencies
test-bot: handle conflicted formulas and unlinked dependencies

these changes are primarily needed for php tap pull requests, as they usally contain multiple formulas depend on conflicting php versions:
- unlink any conflicted formulas
- link any dependencies that are installed and not linked

Closes Homebrew/homebrew#41602.

Signed-off-by: Mike McQuaid <a17fed27eaa842282862ff7c1b9c8395a26ac320@mikemcquaid.com>

toonetown/homebrew,bfontaine/brew,maxim-belkin/brew,vitorgalvao/brew,sjackman/homebrew,hanxue/linuxbrew,toonetown/homebrew,tonyg/homebrew,staticfloat/brew,vitorgalvao/brew,JCount/brew,zmwangx/brew,Linuxbrew/brew,nandub/brew,palxex/brew,Linuxbrew/brew,nandub/brew,gordonmcshane/homebrew,MikeMcQuaid/brew,vitorgalvao/brew,toonetown/homebrew,mistydemeo/homebrew,JCount/brew,aw1621107/brew,Homebrew/brew,nandub/brew,hanxue/linuxbrew,DomT4/brew,konqui/brew,reitermarkus/brew,amar-laksh/brew_sudo,zmwangx/brew,reelsense/brew,muellermartin/dist,alyssais/brew,reitermarkus/brew,mistydemeo/homebrew,bfontaine/brew,gregory-nisbet/brew,DomT4/brew,amar-laksh/brew_sudo,sjackman/homebrew,bfontaine/brew,maxim-belkin/brew,claui/brew,EricFromCanada/brew,claui/brew,mahori/brew,mahori/brew,nandub/brew,mgrimes/brew,alyssais/brew,claui/brew,gregory-nisbet/brew,AnastasiaSulyagina/brew,palxex/brew,mahori/brew,reitermarkus/brew,konqui/brew,konqui/brew,muellermartin/dist,MikeMcQuaid/brew,EricFromCanada/brew,maxim-belkin/brew,jmsundar/brew,tonyg/homebrew,mistydemeo/homebrew,aw1621107/brew,muellermartin/dist,ilovezfs/brew,reelsense/brew,zmwangx/brew,mgrimes/brew,vitorgalvao/brew,JCount/brew,konqui/brew,DomT4/brew,hanxue/linuxbrew,gordonmcshane/homebrew,staticfloat/brew,JCount/brew,MikeMcQuaid/brew,AnastasiaSulyagina/brew,Homebrew/brew,amar-laksh/brew_sudo,Linuxbrew/brew,EricFromCanada/brew,sjackman/homebrew,mgrimes/brew,Homebrew/brew,MikeMcQuaid/brew,jmsundar/brew,Homebrew/brew,ilovezfs/brew,jmsundar/brew,aw1621107/brew,rwhogg/brew,claui/brew,pseudocody/brew,DomT4/brew,EricFromCanada/brew,pseudocody/brew,Linuxbrew/brew,rwhogg/brew,alyssais/brew,rwhogg/brew,sjackman/homebrew,gregory-nisbet/brew,palxex/brew,AnastasiaSulyagina/brew,pseudocody/brew,mahori/brew,reitermarkus/brew,ilovezfs/brew,reelsense/brew,tonyg/homebrew,staticfloat/brew,gordonmcshane/homebrew