Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add kill dependent and group dependent features #1115

Conversation

roulaoregan-spi
Copy link
Contributor

Summarize your change.
As per users' request, migrating a job grouping feature from the old cue.
Kill dependent will suggest killing dependent job every time a job with dependencies gets killed. Group dependents adds a checkbox to cuetopia to allow grouping dependent jobs in the JobMonitor treeView.

@akim-ruslanov
Copy link
Contributor

Python unit test was failing due to the fact that self.stub.GetWhatDependsOnThis was returning a mock within self.stub.GetWhatDependsOnThis. Since the job in the unit test should have no dependency, I suggest the following:

    @mock.patch('cuegui.Utils.questionBoxYesNo', return_value=True)
    def test_kill(self, yesNoMock):
        job = opencue.wrappers.job.Job(opencue.compiled_proto.job_pb2.Job(name='job-name'))
        job.kill = mock.Mock()
        job.getWhatDependsOnThis = mock.Mock()
        job.getWhatDependsOnThis.return_value = []

        self.job_actions.kill(rpcObjects=[job])

        job.kill.assert_called()

Migrate features from old cue. Kill dependent will suggest
killing dependent job every time a job with dependencies
gets killed. Group dependents adds a checkbox to cuetopia
to allow grouping dependent jobs in the JobMonitor treeView.
@roulaoregan-spi
Copy link
Contributor Author

@akim-ruslanov - thank you for looking into the unittest failure and for your suggestion! I'll apply the fix to the branch.

@DiegoTavares DiegoTavares merged commit 671c895 into AcademySoftwareFoundation:master May 2, 2022
DiegoTavares added a commit to DiegoTavares/OpenCue that referenced this pull request May 25, 2022
This line shouldn't have been included in AcademySoftwareFoundation#1115
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants