Best Python code snippet using localstack_python
test_order_matchenv.py
Source:test_order_matchenv.py
...31 sorted_bcc_env = bcc_env[np.lexsort((bcc_env[:,0],bcc_env[:,1],bcc_env[:,2]))]32 npt.assert_equal(num_cluster, 1, err_msg="Number of BCC cluster fail")33 npt.assert_almost_equal(sorted_env_cluster, sorted_bcc_env, decimal=5, err_msg="BCC Cluster Environment fail")34 #by Chrisy35 def test_multi_cluster(self):36 xyz = np.load("sc.npy")37 xyz = np.array(xyz, dtype=np.float32)38 fbox = box.Box.cube(21)39 rcut = 440 kn = 641 threshold = 0.142 match = MatchEnv(fbox, rcut, kn)43 match.cluster(xyz, threshold)44 clusters = match.getClusters()45 cluster_env = {}46 for cluster_ind in clusters:47 if cluster_ind not in cluster_env:48 cluster_env[cluster_ind] = np.copy(np.array(match.getEnvironment(cluster_ind)))49 sc_env = np.load("sc_env.npy")...
test_openshift_namespace_labels.py
Source:test_openshift_namespace_labels.py
...242 run_integration()243 self.state.add.assert_not_called()244 for oc in self.oc_clients.values():245 oc.label.assert_not_called()246 def test_multi_cluster(self):247 """Namespace declared in several clusters. All get updated"""248 self.test_ns = [249 NS(c1, "multi-cluster", k1v1, k1, k1v1_k2v2),250 NS(c2, "multi-cluster", k1v1, k1, k1v1_k2v2),251 ]252 run_integration()253 self.assertEqual(self.state.add.call_count, 2)254 calls = [255 call(state_key(c1, "multi-cluster"), k1_k2, force=True),256 call(state_key(c2, "multi-cluster"), k1_k2, force=True),257 ]258 self.state.add.assert_has_calls(calls)259 self.assertIn(c1, self.oc_clients)260 self.assertIn(c2, self.oc_clients)...
test_pipelines.py
Source:test_pipelines.py
...11 expected = PipelineSettings(name="foo")12 self.assertEqual(expected.name, 'foo')13 self.assertEqual(expected.continuous, False)14 self.assertEqual(expected.channel, 'CURRENT')15 def test_multi_cluster(self):16 js = """{ 17 "cluster_name": "my-cluster",18 "spark_version": "7.3.x-scala2.12",19 "node_type_id": "i3.xlarge",20 "spark_conf": {21 "spark.speculation": true22 },23 "aws_attributes": {24 "availability": "SPOT",25 "zone_id": "us-west-2a"26 },27 "num_workers": 528 }"""29 maint_js = """{ ...
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!!