TST: Making explicit when we run the db tests
State: closed

- [X] closes #23928
- [ ] tests added / passed
- [ ] passes `git diff upstream/master -u -- "*.py" | flake8 --diff`
- [ ] whatsnew entry


Labels:
name: Testing
description: pandas testing functions or related to the test suite
name: IO SQL
description: to_sql, read_sql, read_sql_query
name: CI
description: Continuous Integration

Comments:
you need to leave the skips if not installed

# [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=h1) Report
> Merging [#24450](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=desc) into [master](https://codecov.io/gh/pandas-dev/pandas/commit/08c920eab602dac261b8fe55ffe439593c095e12?src=pr&el=desc) will **not change** coverage.
> The diff coverage is `0%`.

[![Impacted file tree graph](https://codecov.io/gh/pandas-dev/pandas/pull/24450/graphs/tree.svg?width=650&token=eZ4WkYLtcO&height=150&src=pr)](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=tree)

```diff
@@           Coverage Diff           @@
##           master   #24450   +/-   ##
=======================================
  Coverage    92.3%    92.3%           
=======================================
  Files         163      163           
  Lines       51987    51987           
=======================================
  Hits        47989    47989           
  Misses       3998     3998
```

| Flag | Coverage Δ | |
|---|---|---|
| #multiple | `90.72% <0%> (ø)` | :arrow_up: |
| #single | `43% <0%> (ø)` | :arrow_up: |

| [Impacted Files](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [pandas/util/\_tester.py](https://codecov.io/gh/pandas-dev/pandas/pull/24450/diff?src=pr&el=tree#diff-cGFuZGFzL3V0aWwvX3Rlc3Rlci5weQ==) | `23.8% <0%> (ø)` | :arrow_up: |

------

[Continue to review full report at Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=footer). Last update [08c920e...36406be](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).

# [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=h1) Report
> Merging [#24450](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=desc) into [master](https://codecov.io/gh/pandas-dev/pandas/commit/08c920eab602dac261b8fe55ffe439593c095e12?src=pr&el=desc) will **not change** coverage.
> The diff coverage is `0%`.

[![Impacted file tree graph](https://codecov.io/gh/pandas-dev/pandas/pull/24450/graphs/tree.svg?width=650&token=eZ4WkYLtcO&height=150&src=pr)](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=tree)

```diff
@@           Coverage Diff           @@
##           master   #24450   +/-   ##
=======================================
  Coverage    92.3%    92.3%           
=======================================
  Files         163      163           
  Lines       51987    51987           
=======================================
  Hits        47989    47989           
  Misses       3998     3998
```

| Flag | Coverage Δ | |
|---|---|---|
| #multiple | `90.72% <0%> (ø)` | :arrow_up: |
| #single | `43% <0%> (ø)` | :arrow_up: |

| [Impacted Files](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [pandas/util/\_tester.py](https://codecov.io/gh/pandas-dev/pandas/pull/24450/diff?src=pr&el=tree#diff-cGFuZGFzL3V0aWwvX3Rlc3Rlci5weQ==) | `23.8% <0%> (ø)` | :arrow_up: |

------

[Continue to review full report at Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=footer). Last update [08c920e...36406be](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).

# [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=h1) Report
> Merging [#24450](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=desc) into [master](https://codecov.io/gh/pandas-dev/pandas/commit/08c920eab602dac261b8fe55ffe439593c095e12?src=pr&el=desc) will **not change** coverage.
> The diff coverage is `0%`.

[![Impacted file tree graph](https://codecov.io/gh/pandas-dev/pandas/pull/24450/graphs/tree.svg?width=650&token=eZ4WkYLtcO&height=150&src=pr)](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=tree)

```diff
@@           Coverage Diff           @@
##           master   #24450   +/-   ##
=======================================
  Coverage    92.3%    92.3%           
=======================================
  Files         163      163           
  Lines       51987    51987           
=======================================
  Hits        47989    47989           
  Misses       3998     3998
```

| Flag | Coverage Δ | |
|---|---|---|
| #multiple | `90.72% <0%> (ø)` | :arrow_up: |
| #single | `43% <0%> (ø)` | :arrow_up: |

| [Impacted Files](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [pandas/util/\_tester.py](https://codecov.io/gh/pandas-dev/pandas/pull/24450/diff?src=pr&el=tree#diff-cGFuZGFzL3V0aWwvX3Rlc3Rlci5weQ==) | `23.8% <0%> (ø)` | :arrow_up: |

------

[Continue to review full report at Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=footer). Last update [08c920e...36406be](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).

# [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=h1) Report
> Merging [#24450](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=desc) into [master](https://codecov.io/gh/pandas-dev/pandas/commit/08c920eab602dac261b8fe55ffe439593c095e12?src=pr&el=desc) will **not change** coverage.
> The diff coverage is `0%`.

[![Impacted file tree graph](https://codecov.io/gh/pandas-dev/pandas/pull/24450/graphs/tree.svg?width=650&token=eZ4WkYLtcO&height=150&src=pr)](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=tree)

```diff
@@           Coverage Diff           @@
##           master   #24450   +/-   ##
=======================================
  Coverage    92.3%    92.3%           
=======================================
  Files         163      163           
  Lines       51987    51987           
=======================================
  Hits        47989    47989           
  Misses       3998     3998
```

| Flag | Coverage Δ | |
|---|---|---|
| #multiple | `90.72% <0%> (ø)` | :arrow_up: |
| #single | `43% <0%> (ø)` | :arrow_up: |

| [Impacted Files](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [pandas/util/\_tester.py](https://codecov.io/gh/pandas-dev/pandas/pull/24450/diff?src=pr&el=tree#diff-cGFuZGFzL3V0aWwvX3Rlc3Rlci5weQ==) | `23.8% <0%> (ø)` | :arrow_up: |

------

[Continue to review full report at Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=footer). Last update [08c920e...36406be](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).

# [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=h1) Report
> Merging [#24450](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=desc) into [master](https://codecov.io/gh/pandas-dev/pandas/commit/08c920eab602dac261b8fe55ffe439593c095e12?src=pr&el=desc) will **not change** coverage.
> The diff coverage is `0%`.

[![Impacted file tree graph](https://codecov.io/gh/pandas-dev/pandas/pull/24450/graphs/tree.svg?width=650&token=eZ4WkYLtcO&height=150&src=pr)](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=tree)

```diff
@@           Coverage Diff           @@
##           master   #24450   +/-   ##
=======================================
  Coverage    92.3%    92.3%           
=======================================
  Files         163      163           
  Lines       51987    51987           
=======================================
  Hits        47989    47989           
  Misses       3998     3998
```

| Flag | Coverage Δ | |
|---|---|---|
| #multiple | `90.72% <0%> (ø)` | :arrow_up: |
| #single | `43% <0%> (ø)` | :arrow_up: |

| [Impacted Files](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [pandas/util/\_tester.py](https://codecov.io/gh/pandas-dev/pandas/pull/24450/diff?src=pr&el=tree#diff-cGFuZGFzL3V0aWwvX3Rlc3Rlci5weQ==) | `23.8% <0%> (ø)` | :arrow_up: |

------

[Continue to review full report at Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=footer). Last update [08c920e...36406be](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).

# [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=h1) Report
> Merging [#24450](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=desc) into [master](https://codecov.io/gh/pandas-dev/pandas/commit/ab55d05e7a12ebbccfd71511d36efa075fcfa0dc?src=pr&el=desc) will **not change** coverage.
> The diff coverage is `0%`.

[![Impacted file tree graph](https://codecov.io/gh/pandas-dev/pandas/pull/24450/graphs/tree.svg?width=650&token=eZ4WkYLtcO&height=150&src=pr)](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=tree)

```diff
@@           Coverage Diff           @@
##           master   #24450   +/-   ##
=======================================
  Coverage   92.29%   92.29%           
=======================================
  Files         163      163           
  Lines       51948    51948           
=======================================
  Hits        47945    47945           
  Misses       4003     4003
```

| Flag | Coverage Δ | |
|---|---|---|
| #multiple | `90.7% <0%> (ø)` | :arrow_up: |
| #single | `42.99% <0%> (ø)` | :arrow_up: |

| [Impacted Files](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [pandas/util/\_tester.py](https://codecov.io/gh/pandas-dev/pandas/pull/24450/diff?src=pr&el=tree#diff-cGFuZGFzL3V0aWwvX3Rlc3Rlci5weQ==) | `23.8% <0%> (ø)` | :arrow_up: |

------

[Continue to review full report at Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=footer). Last update [ab55d05...6eb3d27](https://codecov.io/gh/pandas-dev/pandas/pull/24450?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).

I was checking that no errors happened when tests were not skipped unless explicitly. All was green, added the skips now.
lgtm. can you just do a ``import pandas; pandas.test()`` to make sure properly skipping when libraries are not installed. I believe we test this in the CI as well.
`pandas.test()` is also skipping the tests
```
pandas/tests/io/test_sql.py ....................................................................................................s....sssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssss [ 66%]
sssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssss...ssssssssssssssssssssssssssssssssssss.................s.............ssssssssss                                                        [ 66%]
```
thanks!