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

Update SBF programs tests to use bank from the correct slot #31491

Merged
merged 1 commit into from
May 4, 2023

Conversation

pgarg66
Copy link
Contributor

@pgarg66 pgarg66 commented May 4, 2023

Problem

Using new LoadedPrograms cache causes test failures in SBF program tests.

Summary of Changes

The failing tests deploy programs and then send transactions to use the newly deployed/upgraded programs. The tests are using the same bank to deploy the program and execute the transactions. Due to delay visibility feature, the program is not effective for 1 slot after deployment. With the new cache (LoadedPrograms) this check uses bank's slot to compute the effective slot of the program.

This change advances the bank_client to the next slot after deployment of the programs.

Fixes #

@pgarg66 pgarg66 requested a review from dmakarov May 4, 2023 18:57
@codecov
Copy link

codecov bot commented May 4, 2023

Codecov Report

Merging #31491 (99a78a3) into master (53aec4a) will decrease coverage by 0.1%.
The diff coverage is 0.0%.

@@            Coverage Diff            @@
##           master   #31491     +/-   ##
=========================================
- Coverage    81.4%    81.4%   -0.1%     
=========================================
  Files         731      731             
  Lines      208720   208729      +9     
=========================================
- Hits       169980   169977      -3     
- Misses      38740    38752     +12     

@pgarg66 pgarg66 merged commit 555520b into solana-labs:master May 4, 2023
@pgarg66 pgarg66 deleted the fix-program-tests branch May 4, 2023 20:25
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.

2 participants