Zum Inhalt springen

Jasmine (JavaScript)

aus Wikipedia, der freien Enzyklopädie
Dies ist eine alte Version dieser Seite, zuletzt bearbeitet am 24. Mai 2013 um 18:20 Uhr durch 85.244.42.52 (Diskussion) (References). Sie kann sich erheblich von der aktuellen Version unterscheiden.

Vorlage:Primary sources

Jasmine
Basisdaten

Entwickler Pivotal Labs
Erscheinungsjahr 12. August 2009
Aktuelle Version 5.8.0[1]
(7. Juni 2025)
Betriebssystem Plattformunabhängig
Programmier­sprache JavaScript
Lizenz MIT-Lizenz[2]
jasmine.github.io

Jasmine is an open source testing framework for JavaScript.[3] It aims to run on any JavaScript-enabled platform, to not intrude on the application nor the IDE, and to have easy-to-read syntax. It is heavily influenced by other unit testing frameworks, such as ScrewUnit, JSSpec, JSpec, and RSpec.[4]

Usage

Jasmine aims to be easy to read. A simple hello world test looks like this:

describe('Hello world', function() {
	it('says hello', function() {
		expect(helloWorld()).toEqual("Hello world!");
	});
});

Jasmine has a number of other features, such as custom matchers, spies, and support for asynchronous specifications.

See also

References

Vorlage:Reflist

Vorlage:Programming-software-stub

  1. Release 5.8.0. 7. Juni 2025 (abgerufen am 18. Juni 2025).
  2. api.github.com. (abgerufen am 19. Oktober 2023).
  3. http://pivotal.github.com/jasmine/
  4. https://github.com/pivotal/jasmine/wiki/Background