Skip to content

Commit

Permalink
Log signature
Browse files Browse the repository at this point in the history
  • Loading branch information
mikemaccana committed Aug 9, 2024
1 parent 46b84cf commit 79570a6
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion basics/favorites/anchor/tests/favorites.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,9 @@ describe('Favorites', () => {
it('Updates the favorites', async () => {
const newFavoriteHobbies = ['skiing', 'skydiving', 'biking', 'swimming'];
try {
await program.methods.setFavorites(favoriteNumber, favoriteColor, newFavoriteHobbies).signers([user]).rpc();
const signature = await program.methods.setFavorites(favoriteNumber, favoriteColor, newFavoriteHobbies).signers([user]).rpc();

console.log(`Transaction signature: ${signature}`);
} catch (error) {
console.error((error as Error).message);
const customErrorMessage = getCustomErrorMessage(systemProgramErrors, error);
Expand Down

0 comments on commit 79570a6

Please sign in to comment.