Commit 910a5cd
authored
test: improve e2e test coverage and documentation (#123)
# Improve E2E Test Coverage and Documentation
## Overview
This pull request enhances the end-to-end test suite by improving error
handling, adding documentation, and refactoring code for better
maintainability.
## Changes
- **Documentation Enhancements:**
- Added detailed comments for each test function to describe their
purpose and functionality.
- Improved error messages for environment variable parsing to provide
clearer feedback.
- **Code Refactoring:**
- Introduced constants for frequently used values such as
`TEST_PRIVATE_KEY` and `DEFAULT_DELEGATION_ADDRESS` to improve code
readability and maintainability.
- Refactored the `assert_chain_advances` test to use a single provider
instance and added a more informative assertion message.
- **Test Improvements:**
- Enhanced the `test_wallet_api` to include more descriptive assertions
and comments.
- Added comments to the `test_withdrawal_proof_with_fallback` to clarify
the test logic and expected outcomes.
## Benefits
- Improved code readability and maintainability through the use of
constants and detailed comments.
- Enhanced error handling and feedback for environment variable parsing.
- Clearer test logic and assertions, making it easier for future
contributors to understand and extend the test suite.
## Testing
- All tests have been run locally and pass successfully.
- No changes to the core functionality, ensuring backward compatibility.
## Related Issues
- N/A1 parent f4fa6b0 commit 910a5cd
1 file changed
+42
-21
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
| 16 | + | |
16 | 17 | | |
17 | 18 | | |
18 | | - | |
| 19 | + | |
19 | 20 | | |
20 | | - | |
| 21 | + | |
21 | 22 | | |
22 | 23 | | |
| 24 | + | |
23 | 25 | | |
24 | 26 | | |
25 | | - | |
| 27 | + | |
26 | 28 | | |
27 | | - | |
| 29 | + | |
28 | 30 | | |
29 | 31 | | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
30 | 39 | | |
31 | 40 | | |
32 | 41 | | |
33 | 42 | | |
34 | 43 | | |
35 | 44 | | |
36 | | - | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
37 | 50 | | |
38 | | - | |
39 | | - | |
| 51 | + | |
| 52 | + | |
40 | 53 | | |
41 | | - | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
42 | 58 | | |
43 | 59 | | |
44 | 60 | | |
45 | 61 | | |
| 62 | + | |
46 | 63 | | |
47 | 64 | | |
48 | 65 | | |
49 | 66 | | |
50 | 67 | | |
51 | 68 | | |
52 | 69 | | |
53 | | - | |
54 | | - | |
55 | | - | |
| 70 | + | |
56 | 71 | | |
57 | 72 | | |
58 | | - | |
59 | | - | |
60 | | - | |
61 | | - | |
| 73 | + | |
| 74 | + | |
62 | 75 | | |
| 76 | + | |
63 | 77 | | |
64 | 78 | | |
65 | 79 | | |
| |||
69 | 83 | | |
70 | 84 | | |
71 | 85 | | |
72 | | - | |
73 | | - | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
74 | 90 | | |
75 | 91 | | |
76 | 92 | | |
77 | | - | |
78 | | - | |
79 | | - | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
80 | 97 | | |
81 | | - | |
| 98 | + | |
| 99 | + | |
82 | 100 | | |
83 | 101 | | |
84 | 102 | | |
| |||
124 | 142 | | |
125 | 143 | | |
126 | 144 | | |
| 145 | + | |
127 | 146 | | |
128 | 147 | | |
129 | 148 | | |
130 | 149 | | |
131 | 150 | | |
132 | 151 | | |
133 | 152 | | |
| 153 | + | |
| 154 | + | |
134 | 155 | | |
135 | 156 | | |
136 | 157 | | |
| |||
0 commit comments