def test_validate(self):
        portfolio = CreateChurchEntity().perform(ChurchData(**Generate.church_data()[0]))
        CreateDomain().perform(portfolio)
        CreateNode().current(portfolio, server=True)

        foreign_porfolio = portfolio.to_portfolio()
        self.assertIsNone(foreign_porfolio.network)
        network = CreateNetwork().perform(portfolio)

        with evaluate("Network:Accept") as report:
            AcceptNetwork().validate(foreign_porfolio, network)
            self.assertIs(network, foreign_porfolio.network)
        self.assertTrue(report)
    def test_validate(self):
        portfolio = CreateChurchEntity().perform(ChurchData(**Generate.church_data()[0]))
        CreateDomain().perform(portfolio)
        CreateNode().current(portfolio, server=True)

        foreign_porfolio = portfolio.to_portfolio()
        self.assertIsNone(foreign_porfolio.network)
        network = CreateNetwork().perform(portfolio)
        AcceptNetwork().validate(foreign_porfolio, network)

        CreateNode().perform(portfolio, device="test", serial="1234567890", ip=IPv4Address("127.0.0.1"), server=True)
        network = UpdateNetwork().perform(portfolio)

        with evaluate("Network:Validate") as report:
            ValidateNetwork().validate(foreign_porfolio, network)
            self.assertIs(network, foreign_porfolio.network)
        self.assertTrue(report)