mirror of
https://gh.wpcy.net/https://github.com/discourse/discourse.git
synced 2026-05-03 15:31:35 +08:00
15 lines
258 B
Ruby
15 lines
258 B
Ruby
# frozen_string_literal: true
|
|
|
|
require "json"
|
|
|
|
module SpecSchemas
|
|
class SpecLoader
|
|
def initialize(filename)
|
|
@filename = filename
|
|
end
|
|
|
|
def load
|
|
JSON.parse(File.read(File.join(__dir__, "json", "#{@filename}.json")))
|
|
end
|
|
end
|
|
end
|