Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a sqlite executor (not in-memory) #48

Merged
merged 2 commits into from
Aug 31, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 9 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,10 @@ jobs:
executor: solidusio_extensions/mysql
steps:
- solidusio_extensions/run-tests
run-specs-with-sqlite:
executor: solidusio_extensions/sqlite
steps:
- solidusio_extensions/run-tests
lint-code:
executor: solidusio_extensions/sqlite-memory
steps:
Expand All @@ -47,6 +51,7 @@ workflows:
jobs:
- run-specs-with-postgres
- run-specs-with-mysql
- run-specs-with-sqlite
- lint-code

"Weekly run specs against master":
Expand All @@ -58,8 +63,7 @@ workflows:
only:
- master
jobs:
- run-specs-with-postgres
- run-specs-with-mysql
- run-specs-with-sqlite
```

Be sure to also enable building the project on CircleCI, otherwise it won't
Expand Down Expand Up @@ -88,26 +92,20 @@ end

We accept Pull Requests on this repository. Any kind of contribution is welcome.

📝 **NOTE:** Currently the first push to a new branch will likely incur into this issue: https://github.com/iynere/compare-url/issues/25. The second push usually fixes the CI.

## Publishing the solidusio/extensions Orb

The [orb-tools Orb](https://github.com/CircleCI-Public/orb-tools-orb) is used
for publishing development and production versions of this Orb.

PRs will create a development release of the Orb, while merging in master will
release a new version of the Orb, using semver and following these rules:

- Modifications to jobs or commands trigger a potential major release
- Modifications to executors, examples, or @orb.yml trigger a minor release
- Modifications to the orb’s config.yml file trigger a patch release
PRs will create a development release of the Orb, while creating GitHub tags and releases
will trigger publishing a new version in the Orb registry.

### Publish a development version from the CLI

Reference: https://circleci.com/docs/2.0/creating-orbs/#using-the-cli-to-publish-orbs

1. Setup the CircleCI CLI (https://circleci.com/docs/2.0/creating-orbs/#step-1---set-up-the-circleci-cli)
2. Buid a one-file version of the orb with `circleci config pack src/ > build/orb.yml`
2. Build a one-file version of the orb with `circleci config pack src/ > build/orb.yml`
3. Publish the ORB with a development version (e.g. one linked to your current PR): `circleci orb publish build/orb.yml solidusio/extensions@dev:pr-123`
4. Test the ORB on a project updating the version `solidusio_extensions: solidusio/extensions@dev:pr-123`

Expand Down
9 changes: 7 additions & 2 deletions src/examples/extension.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,18 @@ usage:
steps:
- browser-tools/install-browser-tools
- solidusio_extensions/run-tests
run-specs-with-sqlite:
executor: solidusio_extensions/sqlite
steps:
- browser-tools/install-browser-tools
- solidusio_extensions/run-tests

workflows:
"Run specs on supported Solidus versions":
jobs:
- run-specs-with-postgres
- run-specs-with-mysql
- run-specs-with-sqlite
"Weekly run specs against master":
triggers:
- schedule:
Expand All @@ -39,5 +45,4 @@ usage:
only:
- master
jobs:
- run-specs-with-postgres
- run-specs-with-mysql
- run-specs-with-sqlite
6 changes: 6 additions & 0 deletions src/executors/sqlite.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
description: Run specs with an in-memory SQLite
docker:
- image: cimg/ruby:2.7-browsers
environment:
RAILS_ENV: test
DB: sqlite