Skip to content

Instantly share code, notes, and snippets.

View MapTo0's full-sized avatar

Martin MapTo0

  • SAP
  • Sofia, Bulgaria
View GitHub Profile
@MapTo0
MapTo0 / Select.js
Created July 15, 2019 07:40
jsdoc example
/**
* @public
*/
const metadata = {
tag: "ui5-select",
slots: /** @lends sap.ui.webcomponents.main.Select.prototype */ {
/**
* Defines the <code>ui5-select</code> options.
* <br/><br/>
import { html, render } from 'lit-html';
import { repeat } from 'lit-html/lib/repeat';
const label = (props) => html`<div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div>
<div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div>
<div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div>
<div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><label id="${props.id}" class=${props.class} style="${props.style}" for="${props.for}" tabindex="${props.tabindex}" title="${props.title}">${props.text}</label></div>`;
const app = (props) => html`<div>
@MapTo0
MapTo0 / sample_rspec.rb
Created October 19, 2016 08:58
Task 2 tests
describe 'Hash#fetch_deep' do
it 'can look up simple values' do
input = {meal: 'musaka'}
expect(input.fetch_deep('meal')).to eq 'musaka'
end
it 'can look up in nested objects' do
input = { menu: {
breakfast: 'banana',
describe '#convert_between_temperature_units' do
it 'converts from Kelvin' do
expect(convert_between_temperature_units(1.2, "K", "F")).to be_within(0.01).of(-457.51)
expect(convert_between_temperature_units(4.2, "K", "C")).to be_within(0.01).of(-268.95)
expect(convert_between_temperature_units(1, "K", "K")).to eq(1)
expect(convert_between_temperature_units(0, "K", "K")).to eq(0)
end
it 'converts from Celsius' do
expect(convert_between_temperature_units(0, 'C', 'K')).to be_within(0.0001).of(273.15)
@MapTo0
MapTo0 / Tests
Last active August 29, 2015 14:10
import java.util.Collections;
import java.util.LinkedList;
import java.util.List;
import java.io.*;
/**
*
* @author Georgi Gaydarov
*
*/