This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// tests/support/schemas/user.json | |
{ | |
"$schema": "http://json-schema.org/draft-04/schema#", | |
"title": "User response schema", | |
"type": "object", | |
"properties": { | |
"data": { | |
"type": "object", | |
"properties": { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# tests/test_users.py | |
import json | |
from .support.assertions import assert_valid_schema | |
def test_get_user(client): | |
# Do whatever is necessary to create a user here… | |
response = client.get('/users/1') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
assert_valid_schema(json_data, 'user.json') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Ember from 'ember'; | |
export default Ember.Controller.extend({ | |
appName: 'Ember Twiddle', | |
hifi: Ember.inject.service(), | |
actions: { | |
play() { | |
const url = "https://stream.wqxr.org/wqxr"; | |
const mimeType = 'audio/mpeg'; |
OlderNewer