I have written a simple class "Test.py".
class Test():
def testMethod():
print('Test method is executed')
I want to execute the method of the class from command prompt.
I am using following command for the same
python -c "from Test import testMethod; testMethod()"
I am getting following error
Traceback (most recent call last):
File "<string>", line 1, in <module>
ImportError: cannot import name 'testMethod' from 'Test'
Can you please help me in identifying the issue in the command in an using