|
78 | 78 | expected_http_requests: VecDeque<(http::Request, http::Response)>, |
79 | 79 | expected_read_data_blob_requests: VecDeque<(DataBlobHash, Vec<u8>)>, |
80 | 80 | expected_assert_data_blob_exists_requests: VecDeque<(DataBlobHash, Option<()>)>, |
81 | | - expected_has_non_trivial_storage_requests: VecDeque<(ApplicationId, bool)>, |
| 81 | + expected_has_trivial_storage_requests: VecDeque<(ApplicationId, bool)>, |
82 | 82 | expected_open_chain_calls: VecDeque<(ChainOwnership, ApplicationPermissions, Amount, ChainId)>, |
83 | 83 | expected_publish_module_calls: VecDeque<ExpectedPublishModuleCall>, |
84 | 84 | expected_create_application_calls: VecDeque<ExpectedCreateApplicationCall>, |
@@ -128,7 +128,7 @@ where |
128 | 128 | expected_http_requests: VecDeque::new(), |
129 | 129 | expected_read_data_blob_requests: VecDeque::new(), |
130 | 130 | expected_assert_data_blob_exists_requests: VecDeque::new(), |
131 | | - expected_has_non_trivial_storage_requests: VecDeque::new(), |
| 131 | + expected_has_trivial_storage_requests: VecDeque::new(), |
132 | 132 | expected_open_chain_calls: VecDeque::new(), |
133 | 133 | expected_publish_module_calls: VecDeque::new(), |
134 | 134 | expected_create_application_calls: VecDeque::new(), |
@@ -938,13 +938,13 @@ where |
938 | 938 | .push_back((hash, response)); |
939 | 939 | } |
940 | 940 |
|
941 | | - /// Adds an expected `has_non_trivial_storage` call, and the response it should return in the test. |
942 | | - pub fn add_expected_has_non_trivial_storage_requests( |
| 941 | + /// Adds an expected `has_trivial_storage` call, and the response it should return in the test. |
| 942 | + pub fn add_expected_has_trivial_storage_requests( |
943 | 943 | &mut self, |
944 | 944 | application: ApplicationId, |
945 | 945 | response: bool, |
946 | 946 | ) { |
947 | | - self.expected_has_non_trivial_storage_requests |
| 947 | + self.expected_has_trivial_storage_requests |
948 | 948 | .push_back((application, response)); |
949 | 949 | } |
950 | 950 |
|
@@ -1009,11 +1009,11 @@ where |
1009 | 1009 | response.expect("Blob does not exist!"); |
1010 | 1010 | } |
1011 | 1011 |
|
1012 | | - /// Returns true if the corresponding contract uses a non-zero amount of storage. |
1013 | | - pub fn has_non_trivial_storage(&mut self, application: ApplicationId) -> bool { |
1014 | | - let maybe_request = self.expected_has_non_trivial_storage_requests.pop_front(); |
| 1012 | + /// Returns true if the corresponding contract uses a zero amount of storage. |
| 1013 | + pub fn has_trivial_storage(&mut self, application: ApplicationId) -> bool { |
| 1014 | + let maybe_request = self.expected_has_trivial_storage_requests.pop_front(); |
1015 | 1015 | let (expected_application_id, response) = |
1016 | | - maybe_request.expect("Unexpected has_non_trivial_storage request"); |
| 1016 | + maybe_request.expect("Unexpected has_trivial_storage request"); |
1017 | 1017 | assert_eq!(application, expected_application_id); |
1018 | 1018 | response |
1019 | 1019 | } |
|
0 commit comments