Skip to content

Commit d833819

Browse files
authored
Merge pull request #458 from xiemaisi/js/more-externs
Approved by asger-semmle
2 parents 969c279 + 79a6cfd commit d833819

File tree

3 files changed

+2349
-1
lines changed

3 files changed

+2349
-1
lines changed

javascript/externs/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ This directory contains externs definitions for improving the precision of some
22

33
Externs are organized into five categories, corresponding to the subdirectories of this directory:
44

5-
* `es`: Externs definitions for the ECMAScript language standard; imported from the `externs` directory of the Google Closure Compiler source tree (https://github.com/google/closure-compiler), revision 6b81fd0bebe9b2560b55a37b880156465d045247.
5+
* `es`: Externs definitions for the ECMAScript language standard; imported from the `externs` directory of the Google Closure Compiler source tree (https://github.com/google/closure-compiler).
66

77
* `web`: Externs definitions for various web standards and browser-specific extensions; imported from the same source.
88

javascript/externs/lib/bdd.js

Lines changed: 96 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,96 @@
1+
/*
2+
* Copyright 2018 Semmle
3+
*
4+
* Licensed under the Apache License, Version 2.0 (the "License");
5+
* you may not use this file except in compliance with the License.
6+
* You may obtain a copy of the License at
7+
*
8+
* http://www.apache.org/licenses/LICENSE-2.0
9+
*
10+
* Unless required by applicable law or agreed to in writing, software
11+
* distributed under the License is distributed on an "AS IS" BASIS,
12+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
* See the License for the specific language governing permissions and
14+
* limitations under the License.
15+
*/
16+
17+
/**
18+
* @fileoverview Simple externs definitions for various BDD and TDD APIs.
19+
*
20+
* The goal is to declare global functions provided by frameworks like Chai,
21+
* Mocha and Jasmine. No type information is included at the moment.
22+
*
23+
* @externs
24+
*/
25+
26+
/** @param {...*} args */
27+
function after(args) {}
28+
29+
/** @param {...*} args */
30+
function afterAll(args) {}
31+
32+
/** @param {...*} args */
33+
function afterEach(args) {}
34+
35+
/** @param {...*} args */
36+
function assert(args) {}
37+
38+
/** @param {...*} args */
39+
function before(args) {}
40+
41+
/** @param {...*} args */
42+
function beforeAll(args) {}
43+
44+
/** @param {...*} args */
45+
function beforeEach(args) {}
46+
47+
/** @param {...*} args */
48+
function context(args) {}
49+
50+
/** @param {...*} args */
51+
function describe(args) {}
52+
53+
/** @param {...*} args */
54+
function expect(args) {}
55+
56+
/** @param {...*} args */
57+
function fdescribe(args) {}
58+
59+
/** @param {...*} args */
60+
function fit(args) {}
61+
62+
/** @param {...*} args */
63+
function it(args) {}
64+
65+
/** @param {...*} args */
66+
function pending(args) {}
67+
68+
/** @param {...*} args */
69+
function setup(args) {}
70+
71+
/** @param {...*} args */
72+
function specify(args) {}
73+
74+
/** @param {...*} args */
75+
function spyOn(args) {}
76+
77+
/** @param {...*} args */
78+
function suite(args) {}
79+
80+
/** @param {...*} args */
81+
function suiteSetup(args) {}
82+
83+
/** @param {...*} args */
84+
function suiteTeardown(args) {}
85+
86+
/** @param {...*} args */
87+
function teardown(args) {}
88+
89+
/** @param {...*} args */
90+
function test(args) {}
91+
92+
/** @param {...*} args */
93+
function xdescribe(args) {}
94+
95+
/** @param {...*} args */
96+
function xit(args) {}

0 commit comments

Comments
 (0)