Skip to content

Instantly share code, notes, and snippets.

View GrimDerp's full-sized avatar
🤠

BC GrimDerp

🤠
View GitHub Profile
@GrimDerp
GrimDerp / json-schema.js
Created January 31, 2022 20:02 — forked from JamesMessinger/json-schema.js
Using JSON Schema in Postman (via an environment variable)
// Load the JSON Schema
const customerSchema = JSON.parse(environment.customerSchema);
// Test whether the response matches the schema
var customer = JSON.parse(responseBody);
tests["Customer is valid"] = tv4.validate(customer, customerSchema);
@GrimDerp
GrimDerp / postman-tests.js
Created January 31, 2022 20:02 — forked from JamesMessinger/postman-tests.js
Postman tests example
tests["Status code is 200"] = responseCode.code === 200;
tests["Response time is acceptable"] = responseTime < 200; // milliseconds
tests["Content-Type header is set"] = postman.getResponseHeader("Content-Type");
@GrimDerp
GrimDerp / set-next-request.js
Created January 31, 2022 20:02 — forked from JamesMessinger/set-next-request.js
setNextRequest() example
var customer = JSON.parse(responseBody);
if (customer.id === undefined) {
// No customer was returned, so don't run the rest of the collection
postman.setNextRequest(null);
}
else {
// Save the customer ID to a Postman environment variable
postman.setEnvironmentVariable("cust_id", customer.id);
@GrimDerp
GrimDerp / OSXApps.md
Created January 31, 2022 20:02 — forked from JamesMessinger/OSXApps.md
James's Great Big List of Great Mac Apps

James’s Great Big List of Great Mac Apps

Apps

  • Chrome ($Free) - Because Safari sucks
  • VLC Media Player ($Free) - Because QuickTime blows
  • Acorn ($30) - Photoshop for humans
  • Airmail ($10) - An excellent email client, supports Gmail, Yahoo, Hotmail, Exchange, etc.
  • Twitter ($Free) - Twitter's official Mac client. It's pretty great.
@GrimDerp
GrimDerp / postman-bdd.js
Created January 31, 2022 20:01 — forked from JamesMessinger/postman-bdd.js
Postman BDD example
describe('Get customer info', () => {
it('should return a valid response', () => {
response.should.have.status(200);
response.should.be.json;
response.body.should.not.be.empty;
});
it('should set the Location header', () => {
response.should.have.header('Location');
@GrimDerp
GrimDerp / index.html
Last active November 20, 2022 10:05
Responsive Web Design Projects - Build a Survey Form
<script src="https://cdn.freecodecamp.org/testable-projects-fcc/v1/bundle.js"></script>
<!doctype html>
<head>
<link rel="stylesheet" href="style.css">
</head>
<h1 style="text-align:center" id="title" style="center" >Super Duper Survey Form</h1>
<p id="description">
<legend style="text-align:center">What do you like about Stuff and Things</legend>
</p>
@GrimDerp
GrimDerp / freecodecampportfoliosite.markdown
Created May 24, 2017 01:43
FreeCodeCampPortfolioSite

FreeCodeCampPortfolioSite

This Pen is a Free Code Camp Portfolio Site built using html & w3.css

A Pen by BC on CodePen.

License.

@GrimDerp
GrimDerp / The Technical Interview Cheat Sheet.md
Last active August 29, 2015 14:28 — forked from tsiege/The Technical Interview Cheat Sheet.md
This is my technical interview cheat sheet. Feel free to fork it or do whatever you want with it. PLEASE let me know if there are any errors or if anything crucial is missing. I will add more links soon.

Studying for a Tech Interview Sucks, so Here's a Cheat Sheet to Help

This list is meant to be a both a quick guide and reference for further research into these topics. It's basically a summary of that comp sci course you never took or forgot about, so there's no way it can cover everything in depth. It also will be available as a gist on Github for everyone to edit and add to.

Data Structure Basics

###Array ####Definition:

  • Stores data elements based on an sequential, most commonly 0 based, index.
  • Based on tuples from set theory.
@GrimDerp
GrimDerp / snowden-ietf93.md
Last active August 29, 2015 14:27 — forked from mnot/snowden-ietf93.md
Transcript of Edward Snowden's comments at IETF93.
/*
* OpenSimplex (Simplectic) Noise Test for Unity (C#)
* This file is in the Public Domain.
*
* This file is intended to test the functionality of OpenSimplexNoise.cs
* Attach this script to a GameObject with mesh (eg a Quad prefab).
* Texture is updated every frame to assist profiling for performance.
* Using a RenderTexture should perform better, however using a Texture2D
* as an example makes this compatible with the free version of Unity.
*