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

[serve] Add tests for backend_state versioning #14748

Merged
merged 16 commits into from
Mar 18, 2021

Conversation

edoakes
Copy link
Contributor

@edoakes edoakes commented Mar 17, 2021

Why are these changes needed?

Related issue number

Checks

  • I've run scripts/format.sh to lint the changes in this PR.
  • I've included any doc changes needed for https://docs.ray.io/en/master/.
  • I've made sure the tests are passing. Note that there might be a few flaky tests, see the recent failures at https://flakey-tests.ray.io/
  • Testing Strategy
    • Unit tests
    • Release tests
    • This PR is not tested :(

@edoakes edoakes changed the title [WIP] backend_state versioning unit tests [serve] Add tests for backend_state versioning Mar 18, 2021
assert mock_replicas[0].started
assert len(replicas(backend_state)) == 1
assert len(replicas(backend_state, states=[ReplicaState.STARTING])) == 1
assert replicas(backend_state)[0]._actor.started
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we want to just keep a reference for all the tests?

starting_replica = replicas(backend_state)[0]

starting_replica._actor.started
...
starting_replica._actor.set_ready()

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah that's probably cleaner. the tests already passed here though so I'm going to merge to unblock my other PR

@edoakes edoakes merged commit de59814 into ray-project:master Mar 18, 2021
@edoakes edoakes added this to the [serve] v2 API milestone Mar 19, 2021
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.

None yet

4 participants