100% found this document useful (2 votes)
10 views

Python Testing Cookbook Easy solutions to test your Python projects using test driven development and Selenium 2nd Edition Greg L. Turnquist & Bhaskar N. Das instant download

The document is a promotional overview of the 'Python Testing Cookbook, 2nd Edition' by Greg L. Turnquist and Bhaskar N. Das, which provides easy solutions for testing Python projects using test-driven development and Selenium. It includes links to download the book and other related resources on test-driven development in various programming languages. Additionally, it highlights the authors' backgrounds and the importance of automated testing in software development.

Uploaded by

yonakasken6y
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
100% found this document useful (2 votes)
10 views

Python Testing Cookbook Easy solutions to test your Python projects using test driven development and Selenium 2nd Edition Greg L. Turnquist & Bhaskar N. Das instant download

The document is a promotional overview of the 'Python Testing Cookbook, 2nd Edition' by Greg L. Turnquist and Bhaskar N. Das, which provides easy solutions for testing Python projects using test-driven development and Selenium. It includes links to download the book and other related resources on test-driven development in various programming languages. Additionally, it highlights the authors' backgrounds and the importance of automated testing in software development.

Uploaded by

yonakasken6y
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 69

Python Testing Cookbook Easy solutions to test

your Python projects using test driven


development and Selenium 2nd Edition Greg L.
Turnquist & Bhaskar N. Das download
https://textbookfull.com/product/python-testing-cookbook-easy-
solutions-to-test-your-python-projects-using-test-driven-
development-and-selenium-2nd-edition-greg-l-turnquist-bhaskar-n-
das/

Download more ebook from https://textbookfull.com


We believe these products will be a great fit for you. Click
the link to download now, or visit textbookfull.com
to discover even more!

Test Driven Development with Python Obey the Testing


Goat Using Django Selenium and JavaScript 2nd Edition
Harry J. W. Percival

https://textbookfull.com/product/test-driven-development-with-
python-obey-the-testing-goat-using-django-selenium-and-
javascript-2nd-edition-harry-j-w-percival/

Python Testing with Selenium: Learn to Implement


Different Testing Techniques Using the Selenium
WebDriver Sujay Raghavendra

https://textbookfull.com/product/python-testing-with-selenium-
learn-to-implement-different-testing-techniques-using-the-
selenium-webdriver-sujay-raghavendra/

Thoughtful machine learning with Python a test driven


approach First Edition Kirk

https://textbookfull.com/product/thoughtful-machine-learning-
with-python-a-test-driven-approach-first-edition-kirk/

Thoughtful Machine Learning with Python A Test Driven


Approach 1st Edition Matthew Kirk

https://textbookfull.com/product/thoughtful-machine-learning-
with-python-a-test-driven-approach-1st-edition-matthew-kirk/
iOS Test Driven Development by Tutorials First Edition
Learn Real World Test Driven Development Joshua Greene

https://textbookfull.com/product/ios-test-driven-development-by-
tutorials-first-edition-learn-real-world-test-driven-development-
joshua-greene/

Test Driven Development in Ruby A Practical


Introduction to TDD Using Problem and Solution Domain
Analysis Paranj

https://textbookfull.com/product/test-driven-development-in-ruby-
a-practical-introduction-to-tdd-using-problem-and-solution-
domain-analysis-paranj/

Python Unit Test Automation. Practical Techniques for


Python Developers and Testers 1st Edition Ashwin
Pajankar

https://textbookfull.com/product/python-unit-test-automation-
practical-techniques-for-python-developers-and-testers-1st-
edition-ashwin-pajankar/

Test Driven Java Development Invoke TDD principles for


end to end application development 2nd Edition Alex
Garcia

https://textbookfull.com/product/test-driven-java-development-
invoke-tdd-principles-for-end-to-end-application-development-2nd-
edition-alex-garcia/

Test Driven Java Development 1st Edition Farcic Viktor


Garcia Alex

https://textbookfull.com/product/test-driven-java-
development-1st-edition-farcic-viktor-garcia-alex/
Python Testing Cookbook
Second Edition

Easy solutions to test your Python projects using test-driven


development and Selenium
Greg L. Turnquist
Bhaskar N. Das

BIRMINGHAM - MUMBAI
Python Testing Cookbook
Second Edition
Copyright © 2018 Packt Publishing

All rights reserved. No part of this book may be reproduced, stored in a retrieval system, or
transmitted in any form or by any means, without the prior written permission of the
publisher, except in the case of brief quotations embedded in critical articles or reviews.

Every effort has been made in the preparation of this book to ensure the accuracy of the
information presented. However, the information contained in this book is sold without
warranty, either express or implied. Neither the author(s), nor Packt Publishing or its
dealers and distributors, will be held liable for any damages caused or alleged to have been
caused directly or indirectly by this book.

Packt Publishing has endeavored to provide trademark information about all of the
companies and products mentioned in this book by the appropriate use of capitals.
However, Packt Publishing cannot guarantee the accuracy of this information.

Commissioning Editor: Merint Matthew


Acquisition Editor: Chaitanya Nair
Content Development Editor: Rohit Singh
Technical Editor: Romy Dias
Copy Editor: Safis Editing
Project Coordinator: Vaidehi Sawant
Proofreader: Safis Editing
Indexer: Pratik Shirodkar
Graphics: Jason Monteiro
Production Coordinator: Deepika Naik

First published: May 2011


Second edition: June 2018

Production reference: 1290618

Published by Packt Publishing Ltd.


Livery Place
35 Livery Street
Birmingham
B3 2PB, UK.

978-1-78712-252-9

www.packtpub.com
mapt.io

Mapt is an online digital library that gives you full access to over
5,000 books and videos, as well as industry leading tools to help you
plan your personal development and advance your career. For more
information, please visit our website.
Why subscribe?
Spend less time learning and more time coding with practical
eBooks and Videos from over 4,000 industry professionals

Improve your learning with Skill Plans built especially for you

Get a free eBook or video every month

Mapt is fully searchable

Copy and paste, print, and bookmark content


PacktPub.com
Did you know that Packt offers eBook versions of every book
published, with PDF and ePub files available? You can upgrade to the
eBook version at www.PacktPub.com and as a print book customer, you are
entitled to a discount on the eBook copy. Get in touch with us at
[email protected] for more details.

At www.PacktPub.com, you can also read a collection of free technical


articles, sign up for a range of free newsletters, and receive
exclusive discounts and offers on Packt books and eBooks.
Contributors
About the authors
Greg L. Turnquist has worked in the software industry since 1997.
He is an active participant in the open source community and has
contributed patches to several projects, including MythTV, Spring
Security, MediaWiki, and the TestNG Eclipse plugin. As a test-
obsessed script junky, he has always sought the right tool for the
job. He is a firm believer in agile practices and automated testing.
He has developed distributed systems and LAMP-based setups, and
he has supported mission-critical systems hosted on various
platforms.
After graduating from Auburn University with a master's in computer
engineering, Greg started working with the Harris Corporation. He
worked on many contracts utilizing many types of technology. In
2006, he created the Spring Python project and went on to write
Spring Python 1.1 in 2010. He joined SpringSource, a division of
VMware in 2010, as part of its international software development
team.

Bhaskar N. Das has 8 years' experience in various projects


involving application development, maintenance, and support with
IBM. He has worked in various technologies and domains including
Java, Python, application servers, the cloud, and various database
technologies. His domain expertise includes finance and asset
management (IT and finance assets). His areas of interest include
big data, business finance optimization and scaling, data science,
and Machine Learning.
About the reviewers
Maurice HT Ling is a Research Assistant Professor at the Perdana
University School of Data Sciences. He obtained his BSc.(Hons.) in
Molecular and Cell Biology from The University of Melbourne,
Australia, in 2004, and his BSc. in Computing from the University of
Portsmouth, United Kingdom, in 2007, before obtaining his Ph.D. in
Bioinformatics from The University of Melbourne, Australia, in 2009.
He is a bioinformatician who is currently working on looking at
evolutionary biology and various aspects of life. His main techniques
involve experimental evolution and simulations, such as artificial life
simulation, for accessing evolutionary perspectives, and using
existing published data. He has developed computational algorithms
as part of this research. He has a wide range of other interests,
including professional and social aspects of science and education,
and studies this area using autoethnographical and autobiographical
methods. He co-founded Python User Group (Singapore), and has
been instrumental in inaugurating PyCon Asia-Pacific as one of the 3
major Python conferences worldwide, together with PyCon US and
EuroPython. On the commercial side, he is the principal partner of
Colossus Technologies LLP, Singapore. In his free time, he likes to
read, enjoy a cup of coffee, writing his personal journal, or
philosophizing on various aspects of life.
Packt is searching for authors
like you
If you're interested in becoming an author for Packt, please visit autho
rs.packtpub.com and apply today. We have worked with thousands of

developers and tech professionals, just like you, to help them share
their insight with the global tech community. You can make a
general application, apply for a specific hot topic that we are
recruiting an author for, or submit your own idea.
Table of Contents
Title Page

Copyright and Credits

Python Testing Cookbook Second Edition

Packt Upsell

Why subscribe?

PacktPub.com

Contributors

About the authors

About the reviewers

Packt is searching for authors like you


Preface

Who this book is for

What this book covers

To get the most out of this book

Download the example code files

Conventions used

Sections

Getting ready

How to do it…

How it works…

There's more…

See also

Get in touch

Reviews
1. Using Unittest to Develop Basic Tests

Introduction

Asserting the basics

Getting ready

How to do it...

How it works...

There's more...

assertEquals is preferred over assertTrue and assertFalse

self.fail([msg]) can usually be rewritten with assertions

Our version of Python can impact our options

Setting up and tearing down a test harness

How to do it...

How it works...

Running test cases from the command line

How to do it...

How it works...

There's more...

Running a subset of test case methods

How to do it...

How it works...

Chaining together a suite of tests

How to do it...

How it works...
There's more...

The name of the test case should be significant


Defining test suites inside the test module

How to do it...
How it works...

There's more...
Test suite methods must be outside of the test class

Why have different suites?


optparse is being phased out and replaced by argparse

Retooling old test code to run inside unittest


How to do it...

How it works...
There's more...
Where are the bugs?
FunctionTestCase is a temporary measure

Breaking down obscure tests into simple ones


How to do it...

How it works...
There's more...

Where is the bug?


What is the right size for a test method?

Unittests versus integration tests


Testing the edges

How to do it...
How it works...

There's more...
Identifying the edges is important

Testing for unexpected conditions


Testing corner cases by iteration

How to do it...
How it works...

There's more...
Does this defy the recipe – breaking down obscure

tests into simple ones?


How does this compare with the recipe – testing th

e edges?
See also
2. Running Automated Test Suites with Nose
Introduction

Getting nosy with testing


How to do it...

How it works...
There's more...
Nose is extensible

Nose is embeddable
See also
Embedding nose inside Python
How to do it...

How it works...
There's more...
Writing a nose extension to pick tests based on regular expressions
Getting ready

How to do it...
How it works...
There's more...
Writing a nose extension to generate a CSV report

Getting ready
How to do it...
How it works...
There's more...

Writing a project-level script that lets you run different test suites
How to do it...
How it works...
There's more...

Why use getopt instead of optparse?


3. Creating Testable Documentation with doctest
Introduction
Documenting the basics

How to do it...
How it works...
There's more...

Catching stack traces


How to do it...
How it works...
Running a doctest from the command line

How to do it...
How it works...
Coding a test harness for doctest
How to do it...

How it works...
There's more...
Filtering out test noise
How to do it...

How it works...
There's more...
Printing out all your documentation including a status report
How to do it...

How it works...
There's more...
Testing the edges
How to do it...

How it works...
There's more...
See also
Testing corner cases by iteration

How to do it...
How it works...
Does this type of test fit better into doctest or unittest?
See also

Getting nosy with doctest


Getting ready
How to do it...
How it works...

Updating the project-level script to run this chapter's doctests


How to do it...
How it works...
There's more...
4. Testing Customer Stories with Behavior-Driven Development
Introduction

Naming tests that sound like sentences and stories


Getting ready
How to do it...
How it works...

There's more...
Testing separate doctest documents
Getting ready 
How to do it...

How it works...
There's more...

Doesn't this defy the usability of docstrings?

Writing a testable story with doctest


Getting ready

How to do it...

How it works...
There's more...

Writing a testable novel with doctest


Getting ready

How to do it...

How it works...
There's more...

Writing a testable story with Voidspace Mock and nose

Getting ready
How to do it...

How it works...
There's more...

Tell me more about the spec nose plugin!

Why didn't we reuse the plugin from the recipe "Naming tests s
o they sound like sentences and stories"?

See also

Writing a testable story with mockito and nose


Getting ready

How to do it...
How it works...
See also

Writing a testable story with Lettuce


Getting ready...

How to do it...

How it works...
There's more...

How complex should a story be?


Don't mix wiring code with application code

Lettuce works great using folders

See also
Using Should DSL to write succinct assertions with Lettuce

Getting ready

How to do it...
How it works...

There's more...
See also

Updating the project-level script to run this chapter's BDD tests

Getting ready
How to do it...

How it works...

See also
5. High-Level Customer Scenarios with Acceptance Testing
Introduction

Installing Pyccuracy

How to do it...
How it works...

See also
Testing the basics with Pyccuracy

Getting ready

How to do it...
How it works...

There's more...

See also
Using Pyccuracy to verify web app security

Getting ready
How to do it...

How it works...

See also
Installing Robot Framework

How to do it...

There's more...
Creating a data-driven test suite with Robot Framework

Getting ready
How to do it...

How it works...

There's more...
Do I have to write HTML tables?

What are the best ways to write the code that implements our c

ustom keywords?
Robot Framework variables are Unicode

See also
Writing a testable story with Robot Framework

Getting ready

How to do it...
How it works...

There's more...

Given-When-Then results in duplicate rules


Do the try-except blocks violate the idea of keeping things li

ght?
See also

Tagging Robot Framework tests and running a subset

Getting ready
How to do it...

How it works...

There's more...
What about documentation?

See also
Testing web basics with Robot Framework

Getting ready...

How to do it...
How it works...

There's more...

Learn about timing configurations – they may be im


portant!

See also
Using Robot Framework to verify web app security

Getting ready

How to do it...
How it works...

There's more...

Why not use a "remember me" option?


Shouldn't we refactor the first test scenario to use the keywo

rd?
Would arguments make the login keyword more flexible?

See also

Creating a project-level script to verify this chapter's acceptance tests


Getting ready

How to do it...

How it works...
There's more

Can we only use getopt?


What's wrong with using the various command-line tools?
6. Integrating Automated Tests with Continuous Integration
Introduction

Generating a CI report for Jenkins using NoseXUnit

Getting ready
How to do it...

How it works...
Configuring Jenkins to run Python tests upon commit

Getting ready

How to do it...
How it works...

There's more...

Do I have to use git for source code management?


What is the format of polling?

See also
Configuring Jenkins to run Python tests when scheduled

Getting ready

How to do it...
How it works...

There's more...

Jenkins versus TeamCity


See also

Generating a CI report for TeamCity using teamcity-nose


Getting ready

How to do it...

How it works...
Configuring TeamCity to run Python tests upon commit

Getting ready

How to do it...
How it works...

There's more...
What did teamcity-nose give us?

See also

Configuring TeamCity to run Python tests when scheduled


Getting ready

How to do it...

How it works...
See also
7. Measuring Your Success with Test Coverage
Introduction

Building a network management application

How to do it...
How it works...

Installing and running coverage on your test suite

How to do it...
There's more...

Why are there no asserts in unittest?


Generating an HTML report using coverage

How to do it...

How it works...
Generating an XML report using coverage

How to do it...

How it works...
What use is an XML report?

See also
Getting nosy with coverage

How to do it...

How it works...
There's more...

Why use the nose plugin instead of the coverage tool directly?

Why are SQLite3 and Spring Python included?


Filtering out test noise from coverage

How to do it...

How it works...

There's more...
See also

Letting Jenkins get nosy with coverage

Getting ready

How to do it...

How it works...
There's more...

Nose doesn't directly support coverage's XML option

Updating the project-level script to provide coverage reports

Getting ready
How to do it...
How it works...

There's more...

Can we only use getopt?


8. Smoke/Load Testing – Testing Major Parts

Introduction

Defining a subset of test cases using import statements


How to do it...

How it works...

There's more...

Security, checking, and integration aren't smoke tests!

What provides good flexibility?


See also

Leaving out integration tests

How to do it...

How it works...

There's more...
Should a smoke test include integration or unit tests?

See also

Targeting end-to-end scenarios

Getting ready

How to do it...

How it works...
There's more...

How does this define smoke tests?

See also

Targeting the test server

Getting ready
How to do it...

How it works...

There's more...

How likely is it that a development and production environment

would use two different database systems?

This isn't just confined to database systems


Coding a data simulator

Getting ready

How to do it...

How it works...

There's more...
Why does the server script initialize the database?
Discovering Diverse Content Through
Random Scribd Documents
No. 17.
TUESDAY, MAY 15, 1750.

——Me non oracula certum,


Sed mors certa facit.

Lucan, lib. ix. 582.

Let those weak minds, who live in doubt and fear,


To juggling priests for oracles repair;
One certain hour of death to each decreed,
My fixt, my certain soul from doubt has freed.

Rowe.

It is recorded of some eastern monarch, that he kept an officer in


his house, whose employment it was to remind him of his mortality,
by calling out every morning, at a stated hour, Remember, prince,
that thou shalt die! And the contemplation of the frailness and
uncertainty of our present state appeared of so much importance to
Solon of Athens, that he left this precept to future ages; Keep thine
eye fixed upon the end of life.
A frequent and attentive prospect of that moment, which must put
a period to all our schemes, and deprive us of all our acquisitions, is
indeed of the utmost efficacy to the just and rational regulation of
our lives; nor would ever any thing wicked, or often any thing
absurd, be undertaken or prosecuted by him who should begin every
day with a serious reflection that he is born to die.
The disturbers of our happiness, in this world, are our desires, our
griefs, and our fears; and to all these, the consideration of mortality
is a certain and adequate remedy. Think, says Epictetus, frequently
on poverty, banishment, and death, and thou wilt then never indulge
violent desires, or give up thy heart to mean sentiments, ουδεν
ουδεποτε ταπεινον ενθυμηση, ουτε αγαν επιθυμησεις τινος.
That the maxim of Epictetus is founded on just observation will
easily be granted, when we reflect, how that vehemence of
eagerness after the common objects of pursuit is kindled in our
minds. We represent to ourselves the pleasures of some future
possession, and suffer our thoughts to dwell attentively upon it, till it
has wholly engrossed the imagination, and permits us not to
conceive any happiness but its attainment, or any misery but its
loss; every other satisfaction which the bounty of Providence has
scattered over life is neglected as inconsiderable, in comparison of
the great object which we have placed before us, and is thrown from
us as incumbering our activity, or trampled under foot as standing in
our way.
Every man has experienced how much of this ardour has been
remitted, when a sharp or tedious sickness has set death before his
eyes. The extensive influence of greatness, the glitter of wealth, the
praises of admirers, and the attendance of supplicants, have
appeared vain and empty things, when the last hour seemed to be
approaching: and the same appearance they would always have, if
the same thought was always predominant. We should then find the
absurdity of stretching out our arms incessantly to grasp that which
we cannot keep, and wearing out our lives in endeavours to add new
turrets to the fabrick of ambition, when the foundation itself is
shaking, and the ground on which it stands is mouldering away.
All envy is proportionate to desire; we are uneasy at the
attainments of another, according as we think our own happiness
would be advanced by the addition of that which he withholds from
us; and therefore whatever depresses immoderate wishes, will, at
the same time, set the heart free from the corrosion of envy, and
exempt us from that vice which is, above most others, tormenting to
ourselves, hateful to the world, and productive of mean artifices, and
sordid projects. He that considers how soon he must close his life,
will find nothing of so much importance as to close it well; and will,
therefore, look with indifference upon whatever is useless to that
purpose. Whoever reflects frequently upon the uncertainty of his
own duration, will find out, that the state of others is not more
permanent, and that what can confer nothing on himself very
desirable, cannot so much improve the condition of a rival, as to
make him much superior to those from whom he has carried the
prize—a prize too mean to deserve a very obstinate opposition.
Even grief, that passion to which the virtuous and tender mind is
particularly subject, will be obviated or alleviated by the same
thoughts. It will be obviated, if all the blessings of our condition are
enjoyed with a constant sense of this uncertain tenure. If we
remember, that whatever we possess is to be in our hands but a
very little time, and that the little which our most lively hopes can
promise us may be made less by ten thousand accidents; we shall
not much repine at a loss, of which we cannot estimate the value,
but of which, though we are not able to tell the least amount, we
know, with sufficient certainty, the greatest; and are convinced that
the greatest is not much to be regretted.
But, if any passion has so much usurped our understanding, as
not to suffer us to enjoy advantages with the moderation prescribed
by reason, it is not too late to apply this remedy, when we find
ourselves sinking under sorrow, and inclined to pine for that which is
irrecoverably vanished. We may then usefully revolve the uncertainty
of our own condition, and the folly of lamenting that from which, if it
had stayed a little longer, we should ourselves have been taken
away.
With regard to the sharpest and most melting sorrow, that which
arises from the loss of those whom we have loved with tenderness,
it may be observed, that friendship between mortals can be
contracted on no other terms, than that one must some time mourn
for the other's death: and this grief will always yield to the survivor
one consolation proportionate to his affliction; for the pain, whatever
it be, that he himself feels, his friend has escaped.
Nor is fear, the most overbearing and resistless of all our passions,
less to be temperated by this universal medicine of the mind. The
frequent contemplation of death, as it shews the vanity of all human
good, discovers likewise the lightness of all terrestrial evil, which
certainly can last no longer than the subject upon which it acts; and
according to the old observation, must be shorter, as it is more
violent. The most cruel calamity which misfortune can produce,
must, by the necessity of nature, be quickly an at end. The soul
cannot long be held in prison, but will fly away, and leave a lifeless
body to human malice.

——Ridetque sui ludibria trunci.

And soaring mocks the broken frame below.

The utmost that we can threaten to one another is that death,


which, indeed, we may precipitate, but cannot retard, and from
which, therefore, it cannot become a wise man to buy a reprieve at
the expense of virtue, since he knows not how small a portion of
time he can purchase, but knows, that whether short or long, it will
be made less valuable by the remembrance of the price at which it
has been obtained. He is sure that he destroys his happiness, but is
not sure that he lengthens his life.
The known shortness of life, as it ought to moderate our passions,
may likewise, with equal propriety, contract our designs. There is not
time for the most forcible genius, and most active industry, to extend
its effects beyond a certain sphere. To project the conquest of the
world, is the madness of mighty princes; to hope for excellence in
every science, has been the folly of literary heroes; and both have
found at last, that they have panted for a height of eminence denied
to humanity, and have lost many opportunities of making themselves
useful and happy, by a vain ambition of obtaining a species of
honour, which the eternal laws of Providence have placed beyond
the reach of man.
The miscarriages of the great designs of princes are recorded in
the histories of the world, but are of little use to the bulk of
mankind, who seem very little interested in admonitions against
errours which they cannot commit. But the fate of learned ambition
is a proper subject for every scholar to consider; for who has not
had occasion to regret the dissipation of great abilities in a
boundless multiplicity of pursuits, to lament the sudden desertion of
excellent designs, upon the offer of some other subject made
inviting by its novelty, and to observe the inaccuracy and deficiencies
of works left unfinished by too great an extension of the plan?
It is always pleasing to observe, how much more our minds can
conceive, than our bodies can perform; yet it is our duty, while we
continue in this complicated state, to regulate one part of our
composition by some regard to the other. We are not to indulge our
corporeal appetites with pleasures that impair our intellectual vigour,
nor gratify our minds with schemes which we know our lives must
fail in attempting to execute. The uncertainty of our duration ought
at once to set bounds to our designs, and add incitements to our
industry; and when we find ourselves inclined either to immensity in
our schemes, or sluggishness in our endeavours, we may either
check, or animate, ourselves, by recollecting, with the father of
physick, that art is long, and life is short.
No. 18.
SATURDAY, MAY 19, 1750.

Illic matre carentibus,


Privignis mulier temperat innocens,
Nec dotata regit virum
Conjux, nec nitido fidit adultero:
Dos est magna parentium
Virtus, et metuens alterius viri
Certo fœdere castitas.

Hor. lib. iii. Ode xxiv. 17.

Not there the guiltless step-dame knows


The baleful draught for orphans to compose;
No wife high portion'd rules her spouse,
Or trusts her essenc'd lover's faithless vows:
The lovers there for dow'ry claim
The father's virtue, and the spotless fame,
Which dares not break the nuptial tie.

Francis.

There is no observation more frequently made by such as employ


themselves in surveying the conduct of mankind, than that marriage,
though the dictate of nature, and the institution of Providence, is yet
very often the cause of misery, and that those who enter into that
state can seldom forbear to express their repentance, and their envy
of those whom either chance or caution hath withheld from it.
This general unhappiness has given occasion to many sage
maxims among the serious, and smart remarks among the gay; the
moralist and the writer of epigrams have equally shewn their abilities
upon it; some have lamented, and some have ridiculed it; but as the
faculty of writing has been chiefly a masculine endowment, the
reproach of making the world miserable has been always thrown
upon the women, and the grave and the merry have equally thought
themselves at liberty to conclude either with declamatory
complaints, or satirical censures, of female folly or fickleness,
ambition or cruelty, extravagance or lust.
Led by such a number of examples, and incited by my share in the
common interest, I sometimes venture to consider this universal
grievance, having endeavoured to divest my heart of all partiality,
and place myself as a kind of neutral being between the sexes,
whose clamours being equally vented on both sides with all the
vehemence of distress, all the apparent confidence of justice, and all
the indignation of injured virtue, seem entitled to equal regard. The
men have, indeed, by their superiority of writing, been able to collect
the evidence of many ages, and raise prejudices in their favour by
the venerable testimonies of philosophers, historians, and poets; but
the pleas of the ladies appeal to passions of more forcible operation
than the reverence of antiquity. If they have not so great names on
their side, they have stronger arguments: it is to little purpose that
Socrates, or Euripides, are produced against the sighs of softness,
and the tears of beauty. The most frigid and inexorable judge would
at least stand suspended between equal powers, as Lucan was
perplexed in the determination of the cause, where the deities were
on one side, and Cato on the other.
But I, who have long studied the severest and most abstracted
philosophy, have now, in the cool maturity of life, arrived at such
command over my passions, that I can hear the vociferations of
either sex without catching any of the fire from those that utter
them. For I have found, by long experience, that a man will
sometimes rage at his wife, when in reality his mistress has offended
him; and a lady complain of the cruelty of her husband, when she
has no other enemy than bad cards. I do not suffer myself to be any
longer imposed upon by oaths on one side, or fits on the other; nor
when the husband hastens to the tavern, and the lady retires to her
closet, am I always confident that they are driven by their miseries;
since I have sometimes reason to believe, that they purpose not so
much to soothe their sorrows, as to animate their fury. But how little
credit soever may be given to particular accusations, the general
accumulation of the charge shews, with too much evidence, that
married persons are not very often advanced in felicity; and,
therefore, it may be proper to examine at what avenues so many
evils have made their way into the world. With this purpose, I have
reviewed the lives of my friends, who have been least successful in
connubial contracts, and attentively considered by what motives they
were incited to marry, and by what principles they regulated their
choice.
One of the first of my acquaintances that resolved to quit the
unsettled thoughtless condition of a bachelor, was Prudentius, a man
of slow parts, but not without knowledge or judgment in things
which he had leisure to consider gradually before he determined
them. Whenever we met at a tavern, it was his province to settle the
scheme of our entertainment, contract with the cook, and inform us
when we had called for wine to the sum originally proposed. This
grave considerer found, by deep meditation, that a man was no
loser by marrying early, even though he contented himself with a
less fortune; for estimating the exact worth of annuities, he found
that considering the constant diminution of the value of life, with the
probable fall of the interest of money, it was not worse to have ten
thousand pounds at the age of two and twenty years, than a much
larger fortune at thirty; for many opportunities, says he, occur of
improving money, which if a man misses, he may not afterwards
recover.
Full of these reflections, he threw his eyes about him, not in
search of beauty or elegance, dignity or understanding, but of a
woman with ten thousand pounds. Such a woman, in a wealthy part
of the kingdom, it was not very difficult to find; and by artful
management with her father, whose ambition was to make his
daughter a gentlewoman, my friend got her, as he boasted to us in
confidence two days after his marriage, for a settlement of seventy-
three pounds a year less than her fortune might have claimed, and
less than he would himself have given, if the fools had been but wise
enough to delay the bargain.
Thus, at once delighted with the superiority of his parts and the
augmentation of his fortune, he carried Furia to his own house, in
which he never afterwards enjoyed one hour of happiness. For Furia
was a wretch of mean intellects, violent passions, a strong voice,
and low education, without any sense of happiness but that which
consisted in eating and counting money. Furia was a scold. They
agreed in the desire of wealth, but with this difference, that
Prudentius was for growing rich by gain, Furia by parsimony.
Prudentius would venture his money with chances very much in his
favour; but Furia very wisely observing, that what they had was,
while they had it, their own, thought all traffick too great a hazard,
and was for putting it out at low interest, upon good security.
Prudentius ventured, however, to insure a ship at a very
unreasonable price, but happening to lose his money, was so
tormented with the clamours of his wife, that he never durst try a
second experiment. He has now grovelled seven and forty years
under Furia's direction, who never once mentioned him, since his
bad luck, by any other name than that of the insurer.
The next that married from our society was Florentius. He
happened to see Zephyretta in a chariot at a horse-race, danced
with her at night, was confirmed in his first ardour, waited on her
next morning, and declared himself her lover. Florentius had not
knowledge enough of the world, to distinguish between the flutter of
coquetry, and the sprightliness of wit, or between the smile of
allurement, and that of cheerfulness. He was soon awaked from his
rapture, by conviction that his pleasure was but the pleasure of a
day. Zephyretta had in four and twenty hours spent her stock of
repartee, gone round the circle of her airs, and had nothing
remaining for him but childish insipidity, or for herself, but the
practice of the same artifices upon new men.
Melissus was a man of parts, capable of enjoying and of improving
life. He had passed through the various scenes of gaiety with that
indifference and possession of himself, natural to men who have
something higher and nobler in their prospect. Retiring to spend the
summer in a village little frequented, he happened to lodge in the
same house with Ianthe, and was unavoidably drawn to some
acquaintance, which her wit and politeness soon invited him to
improve. Having no opportunity of any other company, they were
always together; and as they owed their pleasures to each other,
they began to forget that any pleasure was enjoyed before their
meeting. Melissus, from being delighted with her company, quickly
began to be uneasy in her absence, and being sufficiently convinced
of the force of her understanding, and finding, as he imagined, such
a conformity of temper as declared them formed for each other,
addressed her as a lover, after no very long courtship obtained her
for his wife, and brought her next winter to town in triumph.
Now began their infelicity. Melissus had only seen her in one
scene, where there was no variety of objects, to produce the proper
excitements to contrary desires. They had both loved solitude and
reflection, where there was nothing but solitude and reflection to be
loved; but when they came into publick life, Ianthe discovered those
passions which accident rather than hypocrisy had hitherto
concealed. She was, indeed, not without the power of thinking, but
was wholly without the exertion of that power when either gaiety or
splendour played on her imagination. She was expensive in her
diversions, vehement in her passions, insatiate of pleasure, however
dangerous to her reputation, and eager of applause, by whomsoever
it might be given. This was the wife which Melissus the philosopher
found in his retirement, and from whom he expected an associate in
his studies, and an assistant to his virtues.
Prosapius, upon the death of his younger brother, that the family
might not be extinct, married his housekeeper, and has ever since
been complaining to his friends that mean notions are instilled into
his children, that he is ashamed to sit at his own table, and that his
house is uneasy to him for want of suitable companions.
Avaro, master of a very large estate, took a woman of bad
reputation, recommended to him by a rich uncle, who made that
marriage the condition on which he should be his heir. Avaro now
wonders to perceive his own fortune, his wife's and his uncle's,
insufficient to give him that happiness which is to be found only with
a woman of virtue.
I intend to treat in more papers on this important article of life,
and shall, therefore, make no reflection upon these histories, except
that all whom I have mentioned failed to obtain happiness, for want
of considering that marriage is the strictest tie of perpetual
friendship; that there can be no friendship without confidence, and
no confidence without integrity; and that he must expect to be
wretched, who pays to beauty, riches, or politeness, that regard
which only virtue and piety can claim.
No. 19.
TUESDAY, MAY 22, 1750.

Dum modo causidicum, dum te modo rhetora


fingis,
Et non decernis, Taure, quid esse velis,
Peleos et Priami transit, vel Nestoris, ætas;
Et fuerat serum jam tibi desinere.——
Eia age, rumpe moras: quo te sperabimus usque?
Dum, quid sis, dubitas, jam potes esse nihil.

Mart. lib. ii. Ep. 64.

To rhetorick now, and now to law inclin'd,


Uncertain where to fix thy changing mind;
Old Priam's age or Nestor's may be out,
And thou, O Taures! still go on in doubt.
Come then, how long such wavering shall we see?
Thou may'st doubt on: thou now canst nothing be.

F. Lewis.

It is never without very melancholy reflections, that we can


observe the misconduct, or miscarriage, of those men, who seem,
by the force of understanding, or extent of knowledge, exempted
from the general frailties of human nature, and privileged from the
common infelicities of life. Though the world is crowded with scenes
of calamity, we look upon the general mass of wretchedness with
very little regard, and fix our eyes upon the state of particular
persons, whom the eminence of their qualities marks out from the
multitude; as in reading an account of a battle, we seldom reflect on
the vulgar heaps of slaughter, but follow the hero with our whole
attention, through all the varieties of his fortune, without a thought
of the thousands that are falling round him.
With the same kind of anxious veneration I have for many years
been making observations on the life of Polyphilus, a man whom all
his acquaintances have, from his first appearance in the world,
feared for the quickness of his discernment, and admired for the
multiplicity of his attainments, but whose progress in life, and
usefulness to mankind, has been hindered by the superfluity of his
knowledge, and the celerity of his mind.
Polyphilus was remarkable, at the school, for surpassing all his
companions, without any visible application, and at the university
was distinguished equally for his successful progress as well through
the thorny mazes of science, as the flowery path of politer literature,
without any strict confinement to hours of study, or remarkable
forbearance of the common amusements of young men.
When Polyphilus was at the age in which men usually choose their
profession, and prepare to enter into a publick character, every
academical eye was fixed upon him; all were curious to inquire what
this universal genius would fix upon for the employment of his life;
and no doubt was made but that he would leave all his
contemporaries behind him, and mount to the highest honours of
that class in which he should inlist himself, without those delays and
pauses which must be endured by meaner abilities.
Polyphilus, though by no means insolent or assuming, had been
sufficiently encouraged, by uninterrupted success, to place great
confidence in his own parts; and was not below his companions in
the indulgence of his hopes, and expectations of the astonishment
with which the world would be struck, when first his lustre should
break out upon it; nor could he forbear (for whom does not constant
flattery intoxicate?) to join sometimes in the mirth of his friends, at
the sudden disappearance of those, who, having shone a while, and
drawn the eyes of the publick upon their feeble radiance, were now
doomed to fade away before him.
It is natural for a man to catch advantageous notions of the
condition which those with whom he converses are striving to attain.
Polyphilus, in a ramble to London, fell accidentally among the
physicians, and was so much pleased with the prospect of turning
philosophy to profit, and so highly delighted with a new theory of
fevers which darted into his imagination, and which, after having
considered it a few hours, he found himself able to maintain against
all the advocates for the ancient system, that he resolved to apply
himself to anatomy, botany, and chemistry, and to leave no part
unconquered, either of the animal, mineral, or vegetable kingdoms.
He therefore read authors, constructed systems, and tried
experiments; but, unhappily, as he was going to see a new plant in
flower at Chelsea, he met, in crossing Westminster to take water, the
chancellor's coach; he had the curiosity to follow him into the hall,
where a remarkable cause happened to be tried, and found himself
able to produce so many arguments, which the lawyers had omitted
on both sides, that he determined to quit physic for a profession in
which he found it would be so easy to excel, and which promised
higher honours, and larger profits, without melancholy attendance
upon misery, mean submission to peevishness, and continual
interruption of rest and pleasure.
He immediately took chambers in the Temple, bought a common-
place book, and confined himself for some months to the perusal of
the statutes, year-books, pleadings, and reports; he was a constant
hearer of the courts, and began to put cases with reasonable
accuracy. But he soon discovered, by considering the fortune of
lawyers, that preferment was not to be got by acuteness, learning,
and eloquence. He was perplexed by the absurdities of attorneys,
and misrepresentations made by his clients of their own causes, by
the useless anxiety of one, and the incessant importunity of another;
he began to repent of having devoted himself to a study, which was
so narrow in its comprehension that it could never carry his name to
any other country, and thought it unworthy of a man of parts to sell
his life only for money. The barrenness of his fellow-students forced
him generally into other company at his hours of entertainment, and
among the varieties of conversation through which his curiosity was
daily wandering, he, by chance, mingled at a tavern with some
intelligent officers of the army. A man of letters was easily dazzled
with the gaiety of their appearance, and softened into kindness by
the politeness of their address; he, therefore, cultivated this new
acquaintance, and when he saw how readily they found in every
place admission and regard, and how familiarly they mingled with
every rank and order of men, he began to feel his heart beat for
military honours, and wondered how the prejudices of the university
should make him so long insensible of that ambition, which has fired
so many hearts in every age, and negligent of that calling, which is,
above all others, universally and invariably illustrious, and which
gives, even to the exterior appearance of its professors, a dignity
and freedom unknown to the rest of mankind.
These favourable impressions were made still deeper by his
conversation with ladies, whose regard for soldiers he could not
observe, without wishing himself one of that happy fraternity, to
which the female world seem to have devoted their charms and their
kindness. The love of knowledge, which was still his predominant
inclination, was gratified by the recital of adventures, and accounts
of foreign countries; and therefore he concluded that there was no
way of life in which all his views could so completely concentre as in
that of a soldier. In the art of war he thought it not difficult to excel,
having observed his new friends not very much versed in the
principles of tacticks or fortification; he therefore studied all the
military writers both ancient and modern, and, in a short time, could
tell how to have gained every remarkable battle that has been lost
from the beginning of the world. He often shewed at table how
Alexander should have been checked in his conquests, what was the
fatal errour at Pharsalia, how Charles of Sweden might have escaped
his ruin at Pultowa, and Marlborough might have been made to
repent his temerity at Blenheim. He entrenched armies upon paper
so that no superiority of numbers could force them, and modelled in
clay many impregnable fortresses, on which all the present arts of
attack would be exhausted without effect.
Polyphilus, in a short time, obtained a commission; but before he
could rub off the solemnity of a scholar, and gain the true air of
military vivacity, a war was declared, and forces sent to the
continent. Here Polyphilus unhappily found that study alone would
not make a soldier; for being much accustomed to think, he let the
sense of danger sink into his mind, and felt at the approach of any
action, that terrour which a sentence of death would have brought
upon him. He saw that, instead of conquering their fears, the
endeavour of his gay friends was only to escape them; but his
philosophy chained his mind to its object, and rather loaded him
with shackles than furnished him with arms. He, however,
suppressed his misery in silence, and passed through the campaign
with honour, but found himself utterly unable to support another.
He then had recourse again to his books, and continued to range
from one study to another. As I usually visit him once a month, and
am admitted to him without previous notice, I have found him within
this last half year, decyphering the Chinese language, making a
farce, collecting a vocabulary of the obsolete terms of the English
law, writing an inquiry concerning the ancient Corinthian brass, and
forming a new scheme of the variations of the needle.
Thus is this powerful genius, which might have extended the
sphere of any science, or benefited the world in any profession,
dissipated in a boundless variety, without profit to others or himself!
He makes sudden irruptions into the regions of knowledge, and sees
all obstacles give way before him; but he never stays long enough to
complete his conquest, to establish laws, or bring away the spoils.
Such is often the folly of men, whom nature has enabled to obtain
skill and knowledge, on terms so easy, that they have no sense of
the value of the acquisition; they are qualified to make such speedy
progress in learning, that they think themselves at liberty to loiter in
the way, and by turning aside after every new object, lose the race,
like Atalanta, to slower competitors, who press diligently forward,
and whose force is directed to a single point.
I have often thought those happy that have been fixed, from the
first dawn of thought, in a determination to some state of life, by the
choice of one whose authority may caprice, and whose influence
may prejudice them in favour of his opinion. The general precept of
consulting the genius is of little use, unless we are told how the
genius can be known. If it is to be discovered only by experiment,
life will be lost before the resolution can be fixed; if any other
indications are to be found, they may, perhaps, be very early
discerned. At least, if to miscarry in an attempt be a proof of having
mistaken the direction of the genius, men appear not less frequently
deceived with regard to themselves than to others; and therefore no
one has much reason to complain that his life was planned out by
his friends, or to be confident that he should have had either more
honour or happiness, by being abandoned to the chance of his own
fancy.
It was said of the learned bishop Sanderson, that when he was
preparing his lectures, he hesitated so much, and rejected so often,
that, at the time of reading, he was often forced to produce, not
what was best, but what happened to be at hand. This will be the
state of every man, who, in the choice of his employment, balances
all the arguments on every side; the complication is so intricate, the
motives and objections so numerous, there is so much play for the
imagination, and so much remains in the power of others, that
reason is forced at last to rest in neutrality, the decision devolves
into the hands of chance, and after a great part of life spent in
inquiries which can never be resolved, the rest must often pass in
repenting the unnecessary delay, and can be useful to few other
purposes than to warn others against the same folly, and to shew,
that of two states of life equally consistent with religion and virtue,
he who chooses earliest chooses best.
No. 20.
SATURDAY, MAY 26, 1750.

Ad populum phaleras. Ego te intus, et in cute novi.

Persius, Sat. iii. 30.

Such pageantry be to the people shown;


There boast thy horse's trappings and thy own;
I know thee to thy bottom, from within
Thy shallow centre, to thy utmost skin.

Dryden.

Among the numerous stratagems, by which pride endeavours to


recommend folly to regard, there is scarcely one that meets with
less success than affectation, or a perpetual disguise of the real
character, by fictitious appearances; whether it be, that every man
hates falsehood, from the natural congruity of truth to his faculties
of reason, or that every man is jealous of the honour of his
understanding, and thinks his discernment consequently called in
question, whenever any thing is exhibited under a borrowed form.
This aversion from all kinds of disguise, whatever be its cause, is
universally diffused, and incessantly in action; nor is it necessary,
that to exasperate detestation, or excite contempt, any interest
should be invaded, or any competition attempted; it is sufficient,
that there is an intention to deceive, an intention which every heart
swells to oppose, and every tongue is busy to detect.
This reflection was awakened in my mind by a very common
practice among my correspondents, of writing under characters
which they cannot support, which are of no use to the explanation
or enforcement of that which they describe or recommend; and
which, therefore, since they assume them only for the sake of
displaying their abilities, I will advise them for the future to forbear,
as laborious without advantage.
It is almost a general ambition of those who favour me with their
advice for the regulation of my conduct, or their contribution for the
assistance of my understanding, to affect the style and the names of
ladies. And I cannot always withhold some expression of anger, like
Sir Hugh in the comedy, when I happen to find that a woman has a
beard. I must therefore warn the gentle Phyllis, that she send me no
more letters from the Horse Guards; and require of Belinda, that she
be content to resign her pretentions to female elegance, till she has
lived three weeks without hearing the politicks of Batson's coffee-
house. I must indulge myself in the liberty of observation, that there
were some allusions in Chloris's production, sufficient to shew that
Bracton and Plowden are her favourite authors; and that Euphelia
has not been long enough at home, to wear out all the traces of
phraseology, which she learned in the expedition to Carthagena.
Among all my female friends, there was none who gave me more
trouble to decypher her true character, than Penthesilea, whose
letter lay upon my desk three days before I could fix upon the real
writer. There was a confusion of images, and medley of barbarity,
which held me long in suspense; till by perseverance I disentangled
the perplexity, and found that Penthesilea is the son of a wealthy
stock-jobber, who spends his morning under his father's eye in
Change-Alley, dines at a tavern in Covent-Garden, passes his evening
in the play-house, and part of the night at a gaming-table, and
having learned the dialects of these various regions, has mingled
them all in a studied composition.
When Lee was once told by a critick, that it was very easy to write
like a madman, he answered, that it was difficult to write like a
madman, but easy enough to write like a fool; and I hope to be
excused by my kind contributors, if, in imitation of this great author,
I presume to remind them, that it is much easier not to write like a
man, than to write like a woman.
I have, indeed, some ingenious well-wishers, who, without
departing from their sex, have found very wonderful appellations. A
very smart letter has been sent me from a puny ensign, signed Ajax
Telamonius; another, in recommendation of a new treatise upon
cards, from a gamester, who calls himself Sesostris: and another
upon the improvements of the fishery, from Dioclesian: but as these
seem only to have picked up their appellations by chance, without
endeavouring at any particular imposture, their improprieties are
rather instances of blunder than of affectation, and are, therefore,
not equally fitted to inflame the hostile passions; for it is not folly but
pride, not errour but deceit, which the world means to persecute,
when it raises the full cry of nature to hunt down affectation.
The hatred which dissimulation always draws upon itself, is so
great, that if I did not know how much cunning differs from wisdom,
I should wonder that any men have so little knowledge of their own
interest, as to aspire to wear a mask for life; to try to impose upon
the world a character, to which they feel themselves void of any just
claim; and to hazard their quiet, their fame and even their profit, by
exposing themselves to the danger of that reproach, malevolence,
and neglect, which such a discovery as they have always to fear will
certainly bring upon them.
It might be imagined, that the pleasure of reputation should
consist in the satisfaction of having our opinion of our merit
confirmed by the suffrage of the publick; and that, to be extolled for
a quality, which a man knows himself to want, should give him no
other happiness than to be mistaken for the owner of an estate,
over which he chances to be travelling. But he who subsists upon
affectation, knows nothing of this delicacy; like a desperate
adventurer in commerce, he takes up reputation upon trust,
mortgages possessions which he never had, and enjoys, to the fatal
hour of bankruptcy, though with a thousand terrours and anxieties,
the unnecessary splendour of borrowed riches.
Affectation is to be always distinguished from hypocrisy, as being
the art of counterfeiting those qualities which we might, with
innocence and safety, be known, to want. Thus the man who to
carry on any fraud, or to conceal any crime, pretends to rigours of
devotion, and exactness of life, is guilty of hypocrisy; and his guilt is
greater, as the end, for which he puts on the false appearance, is
more pernicious. But he that, with an awkward address, and
unpleasing countenance, boasts of the conquests made by him
among the ladies, and counts over the thousands which he might
have possessed if he would have submitted to the yoke of
matrimony, is chargeable only with affectation. Hypocrisy is the
necessary burthen of villany, affectation part of the chosen trappings
of folly; the one completes a villain, the other only finishes a fop.
Contempt is the proper punishment of affectation, and detestation
the just consequence of hypocrisy.
With the hypocrite it is not at present my intention to expostulate,
though even he might be taught the excellency of virtue, by the
necessity of seeming to be virtuous; but the man of affectation may,
perhaps, be reclaimed, by finding how little he is likely to gain by
perpetual constraint, and incessant vigilance, and how much more
securely he might make his way to esteem, by cultivating real, than
displaying counterfeit qualities.
Every thing future is to be estimated, by a wise man, in proportion
to the probability of attaining it and its value, when attained; and
neither of these considerations will much contribute to the
encouragement of affectation. For, if the pinnacles of fame be at
best slippery, how unsteady must his footing be who stands upon
pinnacles without foundation! If praise be made by the inconstancy
and maliciousness of those who must confer it, a blessing which no
man can promise himself from the most conspicuous merit and
vigorous industry, how faint must be the hope of gaining it, when
the uncertainty is multiplied by the weakness of the pretensions! He
that pursues fame with just claims, trusts his happiness to the
winds; but he that endeavours after it by false merit, has to fear, not
only the violence of the storm, but the leaks of his vessel. Though
he should happen to keep above water for a time, by the help of a
soft breeze, and a calm sea, at the first gust he must inevitably
founder, with this melancholy reflection, that, if he would have been
content with his natural station, he might have escaped his calamity.
Affectation may possibly succeed for a time, and a man may, by
great attention, persuade others, that he really has the qualities
which he presumes to boast; but the hour will come when he should
exert them, and then whatever he enjoyed in praise, he must suffer
in reproach.
Applause and admiration are by no means to be counted among
the necessaries of life, and therefore any indirect arts to obtain them
have very little claim to pardon or compassion. There is scarcely any
man without some valuable or improveable qualities, by which he
might always secure himself from contempt. And perhaps exemption
from ignominy is the most eligible reputation, as freedom from pain
is, among some philosophers, the definition of happiness.
If we therefore compare the value of the praise obtained by
fictitious excellence, even while the cheat is yet undiscovered, with
that kindness which every man may suit by his virtue, and that
esteem to which most men may rise by common understanding
steadily and honestly applied, we shall find that when from the
adscititious happiness all the deductions are made by fear and
casualty, there will remain nothing equiponderant to the security of
truth. The state of the possessor of humble virtues, to the affecter of
great excellencies, is that of a small cottage of stone, to the palace
raised with ice by the empress of Russia; it was for a time splendid
and luminous, but the first sunshine melted it to nothing.
No. 21.
TUESDAY, MAY 29, 1750.

Terra salutares herbas, eademque nocentes,


Nutrit; et urticæ proxima sæpe rosa est.

Ovid, Rem. Amor. 45.

Our bane and physick the same earth bestows,


And near the noisome nettle blooms the rose.

Every man is prompted by the love of himself to imagine, that he


possesses some qualities, superior, either in kind or in degree, to
those which he sees allotted to the rest of the world; and, whatever
apparent disadvantages he may suffer in the comparison with
others, he has some invisible distinctions, some latent reserve of
excellence, which he throws into the balance, and by which he
generally fancies that it is turned in his favour.
The studious and speculative part of mankind always seem to
consider their fraternity as placed in a state of opposition to those
who are engaged in the tumult of publick business; and have
pleased themselves, from age to age, with celebrating the felicity of
their own condition, and with recounting the perplexity of politicks,
the dangers of greatness, the anxieties of ambition, and the miseries
of riches.
Among the numerous topicks of declamation, that their industry
has discovered on this subject, there is none which they press with
greater efforts, or on which they have more copiously laid out their
reason and their imagination, than the instability of high stations,
and the uncertainty with which the profits and honours are
possessed, that must be acquired with so much hazard, vigilance,
and labour.
This they appear to consider as an irrefragable argument against
the choice of the statesman and the warriour; and swell with
confidence of victory, thus furnished by the muses with the arms
which never can be blunted, and which no art or strength of their
adversaries can elude or resist.
It was well known by experience to the nations which employed
elephants in war, that though by the terrour of their bulk, and the
violence of their impression, they often threw the enemy into
disorder, yet there was always danger in the use of them, very
nearly equivalent to the advantage; for if their first charge could be
supported, they were easily driven back upon their confederates;
they then broke through the troops behind them, and made no less
havock in the precipitation of their retreat, than in the fury of their
onset.
I know not whether those who have so vehemently urged the
inconveniencies and danger of an active life, have not made use of
arguments that may be retorted with equal force upon themselves;
and whether the happiness of a candidate for literary fame be not
subject to the same uncertainty with that of him who governs
provinces, commands armies, presides in the senate, or dictates in
the cabinet.
That eminence of learning is not to be gained without labour, at
least equal to that which any other kind of greatness can require,
will be allowed by those who wish to elevate the character of a
scholar; since they cannot but know, that every human acquisition is
valuable in proportion to the difficulty employed in its attainment.
And that those who have gained the esteem and veneration of the
world, by their knowledge or their genius, are by no means exempt
from the solicitude which any other kind of dignity produces, may be
conjectured from the innumerable artifices which they make use of
to degrade a superior, to repress a rival, or obstruct a follower;
artifices so gross and mean, as to prove evidently how much a man
may excel in learning, without being either more wise or more
virtuous than those whose ignorance he pities or despises.
Nothing therefore remains, by which the student can gratify his
desire of appearing to have built his happiness on a more firm basis
than his antagonist, except the certainty with which his honours are
enjoyed. The garlands gained by the heroes of literature must be
gathered from summits equally difficult to climb with those that bear
the civick or triumphal wreaths, they must be worn with equal envy,
and guarded with equal care from those hands that are always
employed in efforts to tear them away; the only remaining hope is,
that their verdure is more lasting, and that they are less likely to
fade by time, or less obnoxious to the blasts of accident.
Even this hope will receive very little encouragement from the
examination of the history of learning, or observation of the fate of
scholars in the present age. If we look back into past times, we find
innumerable names of authors once in high reputation, read perhaps
by the beautiful, quoted by the witty, and commented on by the
grave; but of whom we now know only that they once existed. If we
consider the distribution of literary fame in our own time, we shall
find it a possession of very uncertain tenure; sometimes bestowed
by a sudden caprice of the publick, and again transferred to a new
favourite, for no other reason than that he is new; sometimes
refused to long labour and eminent desert, and sometimes granted
to very slight pretensions; lost sometimes by security and
negligence, and sometimes by too diligent endeavours to retain it.
A successful author is equally in danger of the diminution of his
fame, whether he continues or ceases to write. The regard of the
publick is not to be kept but by tribute, and the remembrance of
past service will quickly languish, unless successive performances
frequently revive it. Yet in every new attempt there is new hazard,
and there are few who do not at some unlucky time, injure their own
characters by attempting to enlarge them.
There are many possible causes of that inequality which we may
so frequently observe in the performances of the same man, from
the influence of which no ability or industry is sufficiently secured,
and which have so often sullied the splendour of genius, that the
wit, as well as the conqueror, may be properly cautioned not to
indulge his pride with too early triumphs, but to defer to the end of
life his estimate of happiness.

———Ultima semper
Expectanda dies homini, dicique beatus
Ante obitum nemo supremaque funera debet.

Ovid, Met. iii. 135.

But no frail man, however great or high,


Can be concluded blest before he die.

Addison.

Among the motives that urge an author to undertakings by which


his reputation is impaired, one of the most frequent must be
mentioned with tenderness, because it is not to be counted among
his follies, but his miseries. It very often happens that the works of
learning or of wit are performed at the direction of those by whom
they are to be rewarded; the writer has not always the choice of his
subject, but is compelled to accept any task which is thrown before
him without much consideration of his own convenience, and
without time to prepare himself by previous studies.
Miscarriages of this kind are likewise frequently the consequence
of that acquaintance with the great, which is generally considered as
one of the chief privileges of literature and genius. A man who has
once learned to think himself exalted by familiarity with those whom
nothing but their birth, or their fortunes, or such stations as are
seldom gained by moral excellence, set above him, will not be long
without submitting his understanding to their conduct; he will suffer
them to prescribe the course of his studies, and employ him for their
own purposes either of diversion or interest, His desire of pleasing
those whose favour he has weakly made necessary to himself, will
not suffer him always to consider how little he is qualified for the
work imposed. Either his vanity will tempt him to conceal his
deficiencies, or that cowardice, which always encroaches fast upon
such as spend their lives in the company of persons higher than
themselves, will not leave him resolution to assert the liberty of
choice.
But, though we suppose that a man by his fortune can avoid the
necessity of dependance, and by his spirit can repel the usurpations
of patronage, yet he may easily, by writing long, happen to write ill.
There is a general succession of events in which contraries are
produced by periodical vicissitudes; labour and care are rewarded
with success, success produces confidence, confidence relaxes
industry, and negligence ruins that reputation which accuracy had
raised.
He that happens not to be lulled by praise into supineness, may
be animated by it to undertakings above his strength, or incited to
fancy himself alike qualified for every kind of composition, and able
to comply with the publick taste through all its variations. By some
opinion like this, many men have been engaged, at an advanced
age, in attempts which they had not time to complete, and after a
few weak efforts, sunk into the grave with vexation to see the rising
generation gain ground upon them. From these failures the highest
genius is not exempt; that judgment which appears so penetrating,
when it is employed upon the works of others, very often fails where
interest or passion can exert their power. We are blinded in
examining our own labours by innumerable prejudices. Our juvenile
compositions please us, because they bring to our minds the
remembrance of youth; our later performances we are ready to
esteem, because we are unwilling to think that we have made no
improvement; what flows easily from the pen charms us, because
we read with pleasure that which flatters our opinion of our own
powers; what was composed with great struggles of the mind we do
not easily reject, because we cannot bear that so much labour
should be fruitless. But the reader has none of these prepossessions,
and wonders that the author is so unlike himself, without considering
that the same soil will, with different culture, afford different
products.
No. 22.
SATURDAY, JUNE 2, 1750.

——Ego nec studium sine divite venû,


Nec rude quid prosit video ingenium; alterius sic
Altera poscit opem res, et conjurat amice.

Hor. Ars. Poet. 409.

Without a genius learning soars in vain;


And without learning genius sinks again;
Their force united crowns the sprightly reign.

Elphinston.

Wit and Learning were the children of Apollo, by different


mothers; Wit was the offspring of Euphrosyne, and resembled her in
cheerfulness and vivacity; Learning was born of Sophia, and retained
her seriousness and caution. As their mothers were rivals, they were
bred up by them from their birth in habitual opposition, and all
means were so incessantly employed to impress upon them a hatred
and contempt of each other, that though Apollo, who foresaw the ill
effects of their discord, endeavoured to soften them, by dividing his
regard equally between them, yet his impartiality and kindness were
without effect; the maternal animosity was deeply rooted, having
been intermingled with their first ideas, and was confirmed every
hour, as fresh opportunities occurred of exerting it. No sooner were
they of age to be received into the apartments of the other
Welcome to our website – the ideal destination for book lovers and
knowledge seekers. With a mission to inspire endlessly, we offer a
vast collection of books, ranging from classic literary works to
specialized publications, self-development books, and children's
literature. Each book is a new journey of discovery, expanding
knowledge and enriching the soul of the reade

Our website is not just a platform for buying books, but a bridge
connecting readers to the timeless values of culture and wisdom. With
an elegant, user-friendly interface and an intelligent search system,
we are committed to providing a quick and convenient shopping
experience. Additionally, our special promotions and home delivery
services ensure that you save time and fully enjoy the joy of reading.

Let us accompany you on the journey of exploring knowledge and


personal growth!

textbookfull.com

You might also like