Permalink
Browse files

removed "getest" since it is duplication with autotest (and we use ma…

…inly the later for regression testing)
  • Loading branch information...
1 parent 8b33c77 commit b6464cf5e7dbbd82322de59a3c1f87b9bfd2913a @jocelyn jocelyn committed Aug 8, 2012
View
@@ -1,24 +0,0 @@
-class AUTHOR
-
-create
- make
-
-feature {NONE} -- Initialization
-
- make (a_name: UC_STRING) is
- do
- set_name (a_name)
- end
-
-feature -- Access
-
- name: UC_STRING
-
-feature -- Status setting
-
- set_name (a_name: UC_STRING) is
- do
- name := a_name
- end
-
-end -- class AUTHOR
View
@@ -1,40 +0,0 @@
-class BOOK
-
-create
- make
-
-feature {NONE} -- Initialization
-
- make (a_title: UC_STRING; an_author: AUTHOR; an_isbn: UC_STRING) is
- do
- set_title (a_title)
- set_author (an_author)
- set_isbn (an_isbn)
- end
-
-feature -- Access
-
- title: UC_STRING
-
- isbn: UC_STRING
-
- author: AUTHOR
-
-feature -- Status setting
-
- set_title (a_title: UC_STRING) is
- do
- title := a_title
- end
-
- set_author (an_author: AUTHOR) is
- do
- author := an_author
- end
-
- set_isbn (an_isbn: UC_STRING) is
- do
- isbn := an_isbn
- end
-
-end -- class BOOK
@@ -1,82 +0,0 @@
-class BOOK_COLLECTION
-
-create
- make
-
-feature {NONE} -- Initialization
-
- make (a_name: UC_STRING) is
- do
- set_name (a_name)
- create book_index.make (10)
- end
-
-feature -- Access
-
- name: UC_STRING
-
- books: DS_LIST [BOOK] is
- local
- c: DS_HASH_TABLE_CURSOR [DS_LIST [BOOK], UC_STRING]
- do
- from
- create {DS_LINKED_LIST [BOOK]} Result.make
- c := book_index.new_cursor
- c.start
- until
- c.after
- loop
- Result.append_last (c.item)
- c.forth
- end
- end
-
- books_by_author (an_author: UC_STRING): DS_LIST [BOOK] is
- do
- if book_index.has (an_author) then
- Result := book_index @ an_author
- else
- create {DS_LINKED_LIST [BOOK]} Result.make
- end
- end
-
-feature -- Status setting
-
- set_name (a_name: UC_STRING) is
- do
- name := a_name
- end
-
- add_book (a_book: BOOK) is
- local
- l: DS_LIST [BOOK]
- do
- if book_index.has (a_book.author.name) then
- l := book_index @ a_book.author.name
- else
- create {DS_LINKED_LIST [BOOK]} l.make
- book_index.put (l, a_book.author.name)
- end
- l.put_last (a_book)
- end
-
- add_books (book_list: like books) is
- local
- c: DS_LIST_CURSOR [BOOK]
- do
- from
- c := book_list.new_cursor
- c.start
- until
- c.after
- loop
- add_book (c.item)
- c.forth
- end
- end
-
-feature {NONE} -- Implementation
-
- book_index: DS_HASH_TABLE [DS_LIST [BOOK], UC_STRING]
-
-end -- class BOOK_COLLECTION
View
@@ -1,11 +0,0 @@
-echo Compiling ejson_test (finalized)
-ecb -finalize -c_compile -config ejson_test.ecf -batch -clean > NUL 2>&1
-IF %ERRORLEVEL% EQU -1 goto ERROR
-copy EIFGENs\ejson_test\F_code\ejson_test.exe ejson_test.exe
-goto EOF
-
-:ERROR
-echo Error occurred during ejson_test compilation
-goto EOF
-
-:EOF
@@ -1,5 +0,0 @@
-#!/bin/bash
-
-echo "ec -finalize -c_compile -config ejson_test.ecf > /dev/null 2>&1"
-ec -finalize -c_compile -config ejson_test.ecf > /dev/null 2>&1
-cp EIFGENs/ejson_test/F_code/ejson_test .
@@ -1,17 +0,0 @@
--- Gobo test (getest) configuration file for eJSON
-
-test
- ejson_test
-
-default
- class ("TEST_[A-Z0-9_]*")
- feature ("test_[a-z0-9_]*")
- prefix ("X")
- testgen ("TESTGEN")
- compile ("ec_compile.bat")
- execute ("ejson_test.exe")
-
-cluster
- test_dir: "."
-
-end
View
@@ -1,17 +0,0 @@
--- Gobo test (getest) configuration file for eJSON
-
-test
- ejson_test
-
-default
- class ("TEST_[A-Z0-9_]*")
- feature ("test_[a-z0-9_]*")
- prefix ("X")
- testgen ("TESTGEN")
- compile ("./ec_compile.sh")
- execute ("./ejson_test")
-
-cluster
- test_dir: "."
-
-end
View
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="ISO-8859-1"?>
-<system xmlns="http://www.eiffel.com/developers/xml/configuration-1-5-0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.eiffel.com/developers/xml/configuration-1-5-0 http://www.eiffel.com/developers/xml/configuration-1-5-0.xsd" name="ejson_test" uuid="9D4BC920-448B-4F84-9F95-5D47686EBC5E">
- <target name="ejson_test">
- <root class="EJSON_TEST" feature="make"/>
- <file_rule>
- <exclude>//.svn</exclude>
- <exclude>/cvs$</exclude>
- <exclude>/EIFGENs$</exclude>
- </file_rule>
- <option warning="true" void_safety="none" syntax="obsolete">
- <assertions precondition="true" postcondition="true" check="true" invariant="true" loop="true" supplier_precondition="true"/>
- </option>
- <library name="base" location="$ISE_LIBRARY/library/base/base.ecf"/>
- <library name="json" location="../../library/json.ecf"/>
- <library name="json_gobo_extension" location="../../library/json_gobo_extension.ecf"/>
- <library name="gobo_kernel" location="$ISE_LIBRARY/library/gobo/gobo_kernel.ecf"/>
- <library name="gobo_structure" location="$ISE_LIBRARY/library/gobo/gobo_structure.ecf"/>
- <library name="gobo_test" location="$ISE_LIBRARY/library/gobo/gobo_test.ecf"/>
- <cluster name="tests" location="." recursive="true"/>
- </target>
-</system>
@@ -1,55 +0,0 @@
-indexing
- description: "A JSON converter for AUTHOR"
- author: "Paul Cohen"
- date: "$Date$"
- revision: "$Revision$"
-
-class JSON_AUTHOR_CONVERTER
-
-inherit
- JSON_CONVERTER
-
-create
- make
-
-feature {NONE} -- Initialization
-
- make is
- local
- ucs: UC_STRING
- do
- create ucs.make_from_string ("")
- create object.make (ucs)
- end
-
-feature -- Access
-
- value: JSON_OBJECT
-
- object: AUTHOR
-
-feature -- Conversion
-
- from_json (j: like value): like object is
- local
- ucs: UC_STRING
- do
- ucs ?= json.object (j.item (name_key), Void)
- check ucs /= Void end
- create Result.make (ucs)
- end
-
- to_json (o: like object): like value is
- do
- create Result.make
- Result.put (json.value (o.name), name_key)
- end
-
-feature {NONE} -- Implementation
-
- name_key: JSON_STRING is
- once
- create Result.make_json ("name")
- end
-
-end -- class JSON_AUTHOR_CONVERTER
@@ -1,80 +0,0 @@
-indexing
- description: "A JSON converter for BOOK_COLLECTION"
- author: "Paul Cohen"
- date: "$Date$"
- revision: "$Revision$"
-
-class JSON_BOOK_COLLECTION_CONVERTER
-
-inherit
- JSON_CONVERTER
-
-create
- make
-
-feature {NONE} -- Initialization
-
- make is
- local
- ucs: UC_STRING
- do
- create ucs.make_from_string ("")
- create object.make (ucs)
- end
-
-feature -- Access
-
- value: JSON_OBJECT
-
- object: BOOK_COLLECTION
-
-feature -- Conversion
-
- from_json (j: like value): like object is
- local
- ucs: UC_STRING
- ll: DS_LINKED_LIST [BOOK]
- b: BOOK
- ja: JSON_ARRAY
- i: INTEGER
- do
- ucs ?= json.object (j.item (name_key), Void)
- check ucs /= Void end
- create Result.make (ucs)
- ja ?= j.item (books_key)
- check ja /= Void end
- from
- i := 1
- create ll.make
- until
- i > ja.count
- loop
- b ?= json.object (ja [i], "BOOK")
- check b /= Void end
- ll.put_last (b)
- i := i + 1
- end
- check ll /= Void end
- Result.add_books (ll)
- end
-
- to_json (o: like object): like value is
- do
- create Result.make
- Result.put (json.value (o.name), name_key)
- Result.put (json.value (o.books), books_key)
- end
-
-feature {NONE} -- Implementation
-
- name_key: JSON_STRING is
- once
- create Result.make_json ("name")
- end
-
- books_key: JSON_STRING is
- once
- create Result.make_json ("books")
- end
-
-end -- class JSON_BOOK_COLLECTION_CONVERTER
Oops, something went wrong.

0 comments on commit b6464cf

Please sign in to comment.