1
1
Fork
You've already forked json-ld-validate
0
Validation of JSON LD documents
  • Ruby 100%
dmathieu 7eeff0d0c6
All checks were successful
Linting / lint (push) Successful in 56s
Tests / test (3.3) (push) Successful in 40s
Tests / test (3.4) (push) Successful in 41s
Tests / test (4) (push) Successful in 1m43s
Update dependency rubocop to v1.88.2 ( #52 )
This PR contains the following updates:
| Package | Change | [Age](https://docs.renovatebot.com/merge-confidence/) | [Confidence](https://docs.renovatebot.com/merge-confidence/) |
|---|---|---|---|
| [rubocop](https://rubocop.org/) ([source](https://github.com/rubocop/rubocop), [changelog](https://github.com/rubocop/rubocop/releases/tag/v1.88.2)) | `1.88.1` → `1.88.2` | ![age](https://developer.mend.io/api/mc/badges/age/rubygems/rubocop/1.88.2?slim=true) | ![confidence](https://developer.mend.io/api/mc/badges/confidence/rubygems/rubocop/1.88.1/1.88.2?slim=true) |
>  **Important**
>
> Release Notes retrieval for this PR were skipped because no github.com credentials were available.
> If you are self-hosted, please see [this instruction](https://github.com/renovatebot/renovate/blob/master/docs/usage/examples/self-hosting.md#githubcom-token-for-release-notes).
---
### Configuration
📅 **Schedule**: (UTC)
- Branch creation
 - At any time (no schedule defined)
- Automerge
 - At any time (no schedule defined)
🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.
♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 **Ignore**: Close this PR and you won't be reminded about this update again.
---
 - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box
---
This PR has been generated by [Mend Renovate](https://github.com/renovatebot/renovate).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0My4yNTkuMiIsInVwZGF0ZWRJblZlciI6IjQzLjI1OS4yIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJkZXBlbmRlbmNpZXMiLCJydWJ5Il19-->
Co-authored-by: Renovate Bot <forgejo-renovate-action@dmathieu.com>
Reviewed-on: #52 
2026年07月14日 10:41:33 +02:00
.forgejo/workflows Update https://data.forgejo.org/actions/cache action to v6 ( #51 ) 2026年07月07日 09:06:50 +02:00
lib fix linter 2026年05月28日 22:13:24 +02:00
spec Update dependency rubocop-rspec to v3.10.2 ( #47 ) 2026年06月11日 11:51:54 +02:00
.gitignore setup repository 2025年09月14日 13:31:02 +02:00
.rubocop.yml find unknown fields in nested objects too 2026年02月18日 11:29:07 +01:00
.ruby-version Update dependency ruby to v4.0.5 ( #45 ) 2026年05月26日 13:31:21 +02:00
Gemfile setup basic matcher 2025年09月14日 13:50:45 +02:00
Gemfile.lock Update dependency rubocop to v1.88.2 ( #52 ) 2026年07月14日 10:41:33 +02:00
json-ld-validate.gemspec typos and remove unused dependencies 2026年04月14日 21:35:46 +02:00
LICENSE setup repository 2025年09月14日 13:31:02 +02:00
Rakefile setup repository 2025年09月14日 13:31:02 +02:00
README.md setup manual validation class 2025年09月15日 09:51:17 +02:00
renovate.json setup repository 2025年09月14日 13:31:02 +02:00

JSON LD Validate

Validation of JSON LD documents.

Installation

Add this line to your Gemfile:

gem 'json-ld-validate'

RSpec matcher

Within your spec helper, require the gem:

require 'jsonld_validate'

And include the matchers within the rspec configuration:

RSpec.configure do |config|
 config.include JsonldValidate::Matchers
end

Usage

Manuel

You can run the validator manually by using the JsonldValidate::Validator class:

content = {}
v = JsonldValidate::Validator.new(content)
puts v.valid?

RSpec

You can validate a JSON string being valid JSON-LD with the be_valid_jsonld matcher:

require 'spec_helper'
RSpec.describe 'User API' do
	it 'provides json-ld' do
		get :user, id: 1
		expect(response.parsed_body).to be_valid_jsonld
	end
end

Compatibility

JSON LD Validate ensures compatibility with the currently supported versions of the Ruby Language.