Best Python code snippet using localstack_python
test_service_properties.py
Source: test_service_properties.py
...137 # Assert138 received_props = self.bs.get_blob_service_properties()139 self.assertEqual(received_props.target_version, '2014-02-14')140 @record141 def test_set_delete_retention_policy(self):142 # Arrange143 delete_retention_policy = DeleteRetentionPolicy(enabled=True, days=2)144 # Act145 self.bs.set_blob_service_properties(delete_retention_policy=delete_retention_policy)146 # Assert147 received_props = self.bs.get_blob_service_properties()148 self._assert_delete_retention_policy_equal(received_props.delete_retention_policy, delete_retention_policy)149 @record150 def test_set_delete_retention_policy_edge_cases(self):151 # Should work with minimum settings152 delete_retention_policy = DeleteRetentionPolicy(enabled=True, days=1)153 self.bs.set_blob_service_properties(delete_retention_policy=delete_retention_policy)154 # Assert155 received_props = self.bs.get_blob_service_properties()156 self._assert_delete_retention_policy_equal(received_props.delete_retention_policy, delete_retention_policy)157 # Should work with maximum settings158 delete_retention_policy = DeleteRetentionPolicy(enabled=True, days=365)159 self.bs.set_blob_service_properties(delete_retention_policy=delete_retention_policy)160 # Assert161 received_props = self.bs.get_blob_service_properties()162 self._assert_delete_retention_policy_equal(received_props.delete_retention_policy, delete_retention_policy)163 # Should not work with 0 days164 delete_retention_policy = DeleteRetentionPolicy(enabled=True, days=0)165 with self.assertRaises(AzureHttpError):166 self.bs.set_blob_service_properties(delete_retention_policy=delete_retention_policy)167 # Assert168 received_props = self.bs.get_blob_service_properties()169 self._assert_delete_retention_policy_not_equal(received_props.delete_retention_policy, delete_retention_policy)170 # Should not work with 366 days171 delete_retention_policy = DeleteRetentionPolicy(enabled=True, days=366)172 with self.assertRaises(AzureHttpError):173 self.bs.set_blob_service_properties(delete_retention_policy=delete_retention_policy)174 # Assert175 received_props = self.bs.get_blob_service_properties()176 self._assert_delete_retention_policy_not_equal(received_props.delete_retention_policy, delete_retention_policy)177 @record178 def test_set_disabled_delete_retention_policy(self):179 # Arrange180 delete_retention_policy = DeleteRetentionPolicy(enabled=False)181 # Act182 self.bs.set_blob_service_properties(delete_retention_policy=delete_retention_policy)183 # Assert184 received_props = self.bs.get_blob_service_properties()185 self._assert_delete_retention_policy_equal(received_props.delete_retention_policy, delete_retention_policy)186 @record187 def test_set_static_website_properties(self):188 # Arrange189 static_website = StaticWebsite(enabled=True, index_document="index.html",190 error_document_404_path="errors/error/404error.html")191 # Act192 self.bs.set_blob_service_properties(static_website=static_website)...
get_blob_service_properties.py
Source: get_blob_service_properties.py
...51 """52 return pulumi.get(self, "default_service_version")53 @property54 @pulumi.getter(name="deleteRetentionPolicy")55 def delete_retention_policy(self) -> Optional['outputs.DeleteRetentionPolicyResponse']:56 """57 The blob service properties for soft delete.58 """59 return pulumi.get(self, "delete_retention_policy")60 @property61 @pulumi.getter62 def id(self) -> str:63 """64 Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}65 """66 return pulumi.get(self, "id")67 @property68 @pulumi.getter69 def name(self) -> str:...
Check out the latest blogs from LambdaTest on this topic:
Coaching is a term that is now being mentioned a lot more in the leadership space. Having grown successful teams I thought that I was well acquainted with this subject.
The purpose of developing test cases is to ensure the application functions as expected for the customer. Test cases provide basic application documentation for every function, feature, and integrated connection. Test case development often detects defects in the design or missing requirements early in the development process. Additionally, well-written test cases provide internal documentation for all application processing. Test case development is an important part of determining software quality and keeping defects away from customers.
Unit testing is typically software testing within the developer domain. As the QA role expands in DevOps, QAOps, DesignOps, or within an Agile team, QA testers often find themselves creating unit tests. QA testers may create unit tests within the code using a specified unit testing tool, or independently using a variety of methods.
One of the most important skills for leaders to have is the ability to prioritize. To understand how we can organize all of the tasks that must be completed in order to complete a project, we must first understand the business we are in, particularly the project goals. There might be several project drivers that stimulate project execution and motivate a company to allocate the appropriate funding.
Learn to execute automation testing from scratch with LambdaTest Learning Hub. Right from setting up the prerequisites to run your first automation test, to following best practices and diving deeper into advanced test scenarios. LambdaTest Learning Hubs compile a list of step-by-step guides to help you be proficient with different test automation frameworks i.e. Selenium, Cypress, TestNG etc.
You could also refer to video tutorials over LambdaTest YouTube channel to get step by step demonstration from industry experts.
Get 100 minutes of automation test minutes FREE!!