How to use print_test_names method in localstack

Best Python code snippet using localstack_python

cli.py

Source:cli.py Github

copy

Full Screen

...224) Press '4' to run PCA before data training235) Press 'q' to exit24 '''25 print(usage)26 def print_test_names(self) :27 names = ['biker', 'bird1', 'blurbody', 'blurcar2', 'bolt', 'cardark', 'football', 'human3', 'human6', 'human9', 'panda', 'walking', 'walking2']28 for n in names:29 print(' - ', n)30 def handle_app_a(self):31 usage = '''32APP A (Simple Detection):33-------------------------341) Press '1' to try training of object types352) Press '2' to run a test detection363) Press '0' to return to main menu37 '''38 print(usage)39 key = input()40 while key != '0':41 if(key == '1'):42 train_app_a.train()43 elif(key == '2'):44 print('Give 3 test names:')45 self.print_test_names()46 tests = ['a'] * 347 tests[0] = input()48 tests[1] = input()49 tests[2] = input()50 run_app_a.run(tests)51 else:52 print('Wrong input entered. Try again')53 print(usage)54 key = input()55 def handle_app_b(self):56 usage = '''57APP B (Detection + Tracking):58----------------------------591) Press '1' to train using CNN based position annotation602) Press '2' to try APP B on a sample image613) Press '3' to try APP B on sample video clip with both approaches combined624) Press '4' to train with hypertuning of CNN layers, activation functions and feature map635) Press '0' to return to main menu64'''65 print(usage)66 key = input()67 while key != '0':68 if(key == '1'):69 print('Provide test name to train:')70 self.print_test_names()71 test = input()72 train_app_b.train(test)73 elif(key=='2'):74 print('Provide test name to run:')75 self.print_test_names()76 test = input()77 run_app_b.run(test)78 elif(key=='3'):79 print('Enter test name to run the clip: ')80 self.print_test_names()81 test = input()82 run_app_b_vid.run(test)83 elif(key=='4'):84 print('Enter test name to run the clip: ')85 self.print_test_names()86 test = input()87 train_app_b_tuning.train(test)88 else:89 print('Invalid input entered. Try again.')90 print(usage)91 key=input()92 def handle_app_c(self):93 usage = '''94APP C (OpenCV based Detection):95-------------------------------96(Please note that this approach uses HUD based cascade approach.)971) Press '1' to train the trainer.yml 982) Press '2' to try a sample video clip993) Press '0' to go to main menu.100'''101 print(usage)102 key = input()103 while key != '0':104 if(key == '1'):105 print('Please enter a test case name: ')106 self.print_test_names()107 test = input()108 train_app_c.train(test)109 elif(key == '2'):110 print('Please enter a test case name: ')111 self.print_test_names()112 test = input()113 run_app_c.run(test)114 else:115 print('Wrong input entered')116 print(usage)117 key = input()118 def handle_pca(self):119 usage = '''120Enter test name or 0 to return to main menu:121'''122 print(usage)123 self.print_test_names()124 key = input()125 while key != '0':126 apply_pca.apply_pca(key)127 print(usage)128 self.print_test_names()129 key = input()130################################################################################131# Entry point for the application132################################################################################133if __name__ == '__main__':134 cli = CLI()135 cli.print_usage()136 key = input()137 while key != 'q':138 if(key == '1'):139 cli.handle_app_a()140 elif(key == '2'):141 cli.handle_app_b()142 elif(key == '3'):...

Full Screen

Full Screen

get-tf-tests.py

Source:get-tf-tests.py Github

copy

Full Screen

1import sys2import yaml3def print_test_names(service):4 with open("tests/terraform/terraform-tests.yaml") as f:5 dct = yaml.load(f, Loader=yaml.FullLoader)6 tests = dct.get(service)7 # exits if no tests are specified under service in yaml file8 if not tests:9 sys.exit(1)10 if len(tests) == 1:11 print(tests[0])12 else:13 print('"(' + "|".join(tests) + ')"')14if __name__ == "__main__":15 # not tests should run if no arguments are provided16 if len(sys.argv) != 2:17 sys.exit(1)18 else:...

Full Screen

Full Screen

get_tf_tests.py

Source:get_tf_tests.py Github

copy

Full Screen

1import yaml2import sys3def print_test_names(service):4 with open("tests/terraformtests/terraform-tests.success.txt") as f:5 dct = yaml.load(f, Loader=yaml.FullLoader)6 tests = dct.get(service)7 if len(tests) == 1:8 print(tests[0])9 else:10 print('"(' + "|".join(tests) + ')"')11if __name__ == "__main__":12 if len(sys.argv) != 2:13 print("")14 else:...

Full Screen

Full Screen

Automation Testing Tutorials

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.

LambdaTest Learning Hubs:

YouTube

You could also refer to video tutorials over LambdaTest YouTube channel to get step by step demonstration from industry experts.

Run localstack automation tests on LambdaTest cloud grid

Perform automation testing on 3000+ real desktop and mobile devices online.

Try LambdaTest Now !!

Get 100 minutes of automation test minutes FREE!!

Next-Gen App & Browser Testing Cloud

Was this article helpful?

Helpful

NotHelpful